Menu

DataMatrix ASP.NET Web Control without MS Visual Studio

Method 1. Using DataMatrix ASP.NET Web Control without integrating it with Visual Studio.

 
This method of creating barcodes can be used in any environment. You only need a computer with the IIS server installed on it and .NET for that. The following steps demonstrate how DataMatrix ASP.NET Web Control can be used in this mode.

Create a Virtual Directory or a Site. You can also use Microsoft Visual Studio and create a new Web Application.
  To create a virtual directory, follow these steps:
1. Open the control panel of the IIS server and right-click "Default Web Site".
2. Use the IIS Wizard to create a virtual directory.

Create IIS virtual directory.
  
Create physical directories named test and bin (inside the test directory).
  Copy the file ASPDataMatrixGenerator.aspx to the test directory

Copy the files into the test directory.

Copy the files Barcodes.DataMatrixWeb.dll and ASPDataMatrixGenerator.dll to the bin directory

Copy the files into the bin directory.
  
You can use DataMatrix barcode already now.
  To do it, just start your Internet Browser and type in the address line:
http://localhost/test/ASPDataMatrixGenerator.aspx

You should see a barcode.

DataMatrix in the Microsoft Internet Explorer

To customize the barcode, you can use the parameters described here.
  
You can create any HTML page with a DataMatrix barcode in it.
  For example, create the file example.html. Here you can see the source code of this file:
<html>
<body>
<h1>DataMatrix ASP.NET Web Generator</h1>
<img src="http://localhost/test/ASPDataMatrixGenerator.aspx?data=Hello+World&
fmt=30&w=200&h=100" width=200 height=100>
</body>
</html>
As a result, you should see the following HTML page with a DataMatrix barcode in it.

DataMatrix in the Microsoft Internet Explorer. Using HTML.
  
Parameters to customize the barcode.
  You can specify these parameters in the address line after the '?' character. For instance, to encode the string '1234567' into the barcode, you should specify the following address line:
http://localhost/test/ASPDataMatrixGenerator.aspx?data=1234567

ParameterDescription
dataDataToEncode property
fmtPreferredFormat property
modeEncodingMode property
angleOrientation property
quietQuietZone property
alignhAlignH property
alignvAlignV property
bcolorBackColor property
fcolorForeColor property
qjpegJPEGQuality property
imgSpecifies the image format extension ('jpeg', 'gif', etc)
wBarcode image width
hBarcode image height