using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Drawing;
using System.Drawing.Imaging;
using Neodynamic.WebControls.BarcodeProfessional;
using System.IO;
namespace WebApplication
{
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
GetImage();
byte[] code = GetUpDownImage("888.png");
if (code != null)
{
Response.Clear();
Response.ContentType = "image/png";
Response.BinaryWrite(code);
Response.End();
}
else
{
Response.End();
}
}
protected void btn_Click(object sender, EventArgs e)
{
Response.Write(txt.Text);
}
protected void GetImage()
{
//生成条码
BarcodeProfessional bcp = new BarcodeProfessional(); //BarcodeProfessional第三方程序集
bcp.Code = "W002054965001";
bcp.Symbology = Symbology.Code39;
byte[] barcodeImage = bcp.GetBarcodeImage(System.Drawing.Imaging.ImageFormat.Png);
//if (barcodeImage != null)
//{
// Response.Clear();
// Response.ContentType = "image/gif";
// Response.BinaryWri