The barcode component is based on the TImage and so inherits many of its properties from this object. Over and above this, the component supports properties specific to its application, in this case the production of Barcodes. The component can be placed on a form and its properties set a Design time or altered through code at Run-Time.
A sample application is included in the form of the dBarcode1 project, which includes the UNIT1.PAS source file.
A typical example is shown below
procedure
TForm1.DoBarcode2D();
begin
Barcode2D1.Xunit:=50;
Barcode2D1.Yunit:=200;
Barcode2D1.BarcodeType:=2;
Barcode2D1.StartMode:=0;
Barcode2D1.SecurityLevel:=0;
Barcode2D1.AspectRatio:=1.0;
Barcode1.Caption:=Edit1.Text;
errormessage.Text:=Barcode2D1.GetError(Barcode2D1.Error);
end;
More: