VintaSoft Barcode .NET SDK v10.0
In This Topic
    Get barcode image as System.Windows.Media.PathGeometry object in WPF
    In This Topic

    Example: Here is an example that shows how to get barcode in vector form as PathGeometry object.

    Public Function GetBarcodeAsPathGeometry(barcode As BarcodeType, value As String) As PathGeometry
            ' create the barcode writer
            Dim barcodeWriter As New BarcodeWriter()
            ' set barcode writer settings
            barcodeWriter.Settings.Barcode = barcode
            barcodeWriter.Settings.Value = value
            ' return barcode as PathGeometry
            Return barcodeWriter.GetBarcodeAsPathGeometry()
    End Function
    public PathGeometry GetBarcodeAsPathGeometry(BarcodeType barcode, string value)
        // create the barcode writer
        BarcodeWriter barcodeWriter = new BarcodeWriter();
        // set barcode writer settings
        barcodeWriter.Settings.Barcode = barcode;
        barcodeWriter.Settings.Value = value;
        // return barcode as PathGeometry
        return barcodeWriter.GetBarcodeAsPathGeometry();