Link Search Menu Expand Document

Getting Started in VB.NET (non-visual class)

The following example demonstrates how to generate barcode image using non-visual Barcode class in Visual Basic.NET

First Step
VB
Imports Bytescout.BarCode

Module Module1

    Sub Main()
        ' Create new barcode
        Dim barcode As New Barcode()

        ' Set symbology
        barcode.Symbology = SymbologyType.Code39
        ' Set value
        barcode.Value = "Sample"

        ' Save barcode to image
        barcode.SaveImage("result.png")

        ' Show image in default image viewer
        Process.Start("result.png")
    End Sub

End Module