QR Code Image Sample - pqScan.com
ASP.NET EAN-13 Creator Web Forms Control Encoding EAN-13 Barcode Image in ASP.NET Web forms Online Demo Download Trial Purchase Now
.NET Winforms
ASP.NET
C#-VB

How to Generate EAN-13 in ASP.NET Web Server?

back to home  >  .NET Barcode Generator SDK  >  Generate Barcodes in ASP.NET  >  Generate EAN-13 in ASP.NET

ASP.NET EAN-13 Creator is one of the barcode generation functions in pqScan Barcode Creator for ASP.NET. At the same way to other types of barcode, generating EAN-13 through Barcode Creator Web Control is most convenient for developers.

If you want to learn more about creating barcodes in ASP.NET application, you can see Date Matrix in web, PDF417 in web, QR Code in web, Aztec Code in web.

Generating EAN-13 use Barcode Web Control in ASP.NET Web Application

Barcode Creator Web Control on pages can run in both Visual Studio and IIS web applications. Before using, you need download pqScan Barcode Creator SDK firstly.

Creating EAN-13 use ASP.NET Barcode Creator Web Control in Visual Studio

Using the pqScan Barcode Creator WebForms control to render EAN-13 image, follow these steps:

  1. Unzip the downloaded Trial package to development computer.
  2. Add Barcode Creator Webforms Control to the Visual studio Toolbox.
    • In the ASP.NET Web application, show the ToolBox pane.
    • Right click on the General pane and select Choose Items...
    • In the pop-up dialog Choose Toolbox Items, ensure the .NET Framework Components tab is displayed.
    • Push the Browse button and navigate to the "PQScan.BarcodeCreator.dll" file.
    • Ensure the checkbox "BarcodeWebControl" is checked.
  3. With a project's web form open in design mode, drag the "BarcodeWebControl" item from toolbox onto the web form.
  4. Copy "BarcodeWebHandler.ashx" file in to your ASP.NET web site.

Creating EAN-13 use ASP.NET Barcode Creator Web Control in IIS

  1. Unzip the downloaded Trial package to development computer.
  2. Publish you APS.NET web site to your IIS.
  3. Copy "PQScan.BarcodeCreator.dll" file to your IIS bin forder.
  4. Copy "BarcodeWebHandler.ashx" file to your IIS root path.
  5. Create an empty html at root path, insert an image tag like this: <img src="http://localhost:port/BarcodeWebHandler.ashx?BarType=EAN13&Data=123456789012&Width=200&Height=100&ShowText=True"/>
  6. Viewing html page on web browser, you will see the EAN-13 barcode made on the page.

Note: When you use pqScan Barcode Creator Web Control to encode EAN-13, please ensure the "BarcodeWebHandler.ashx" file is copied to the folder where the web pages you want to generate EAN-13 barcodes in both ways above.

Note: Generating a EAN-13 barcode image both in Visual Studio web site and in IIS, the src property of <img> tag can be changed by javascript to customize barcode image, and there is no need to refresh whole web page.

Generating EAN-13 use ASP.NET Barcode Creator component API

To encode EAN-13 image in web form class using Barcode Creator methods of Library, follow these steps:

  1. Download and unzip the Trial package to development computer.
  2. Add "PQScan.BarcodeCreator.dll" to your ASP.NET Web form project reference.(The DLL will be copied automatically to the project bin folder).
  3. Add following C# code to your ASP.NET Web from class:
using System;
using System.Web;
using System.Web.UI;
using PQScan.BarcodeCreator;

namespace EAN13GeneratorInWeb
{
    public partial class WebForm1 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            Barcode ean13 = new Barcode();

            ean13.Data = "123456789012";
            ean13.BarType = BarCodeType.EAN13;
            ean13.Width = 200;
            ean13.Height = 100;
            ean13.ShowText = true;

            ean13.CreateBarcode("ean13-webforms.png");

        }
    }
}

generate ean13 in asp.net

.NET Barcode Creator QR Code Creator in ASP.NET Data Matrix Creator in ASP.NET PDF 417 Creator in ASP.NET Aztec Creator in ASP.NET EAN 8 Creator in ASP.NET UPC A Creator in ASP.NET Code 128 Creator in ASP.NET Code 39 Creator in ASP.NET