Barcode Xpress for ActiveX v14.0 - Updated
Developer Guide / How To / Create a Barcode
In This Topic
    Create a Barcode
    In This Topic

    Basic Steps to Create a Barcode

    1. Set the Barcode Value and Type you want to create. 
    2. Call the MakeBarcode method to create a barcode.
    3. Get the resulting image.
    VB6  Example - Minimum VB code to write
    Copy Code
    'set the required writer properties
    BarcodeXpress1.MakeBarcodeStyle=BC_StyleCode39
    BarcodeXpress1.MakeBarcodeValue="CODE39"
    
    'call MakeBarcode to create barcode
    BarcodeXpress1.MakeBarcode
    
    'get the resulting image from MakeBarcodeDIB (or MakeBarcodePic) property
    ImagXpress1.hDib = BarcodeXpress1.MakeBarcodeDIB
    

    1D barcode values are generally 7 bit ASCII, except for Code 128, which permits the use of 8 bit data. If you are using values above 127, you must use the SetMakeBarcodeDataValue method instead of the MakeBarcodeValue property, and your data must be encoded. Also, the reader and writer must both use the same character set. 

    See the Try the Sample Applications topic for more code examples on writing barcodes.

    Barcode Xpress provides many additional methods and properties to use in barcode creation. See the Accusoft BarcodeXpress namespace topic for API information on methods and properties.

     

    See Also