|
|
Print PDF417 Barcode In Visual Basic
If you download and install the demo of Barcodesoft PDF417 font on your computer,
you will find crUFLBCS.dll from
"C:\Program Files\Common Files\Barcodesoft\Fontutil\" folder.
crUFLBCS.dll is a COM object with IPDF417 interface.
You can find the detailed information about this interface from readme.html.
To call the method of this interface, you can use either Late Binding or Early Binding.
Late binding is used when type information of an object is unavailable at compile time.
Early binding requires the client to get access to the type library before compile.
Late Binding
Open LateBindingSample.frm with Visual Basic from
C:\Program Files\Barcodesoft\pdf417font\ folder.
Dim cruflBCSObj As Object
Set cruflBCSObj = CreateObject("cruflBCS.PDF417.1")
cruflBCSObj.SetCRLF (1)
Dim retval As String
retval = cruflBCSObj.Encode(strTemp, "0")
Now, apply font typeface BCSPDF417 to returned string "retval". You will see PDF417 barcode.
Early Binding
Open EarlyBindingSample.frm with Visual Basic from the following folder
C:\Program Files\Barcodesoft\pdf417font\.
Click Project menu, choose References item to load the type information of crUFLBCS.dll.
Dim cruflBCSObj As Object
Set cruflBCSObj = CreateObject("cruflBCS.PDF417.1")
cruflBCSObj.SetCRLF (1)
Dim retval As String
retval = cruflBCSObj.Encode(strTemp, "0")
Dim obj As cruflBCS.CBCSPDF417
Set obj = New cruflBCS.CBCSPDF417
pdf417 = obj.Encode(strToEncode, "0")
Set obj = Nothing
2. Use the following code snippet to print barcode from Visual Basic.
Dim obj As cruflBCS.CBCSPDF417
Set obj = New cruflBCS.CBCSPDF417
pdf417 = obj.Encode(strToEncode, "0")
Set obj = Nothing
For more information about PDF417 barcode, please click pdf417.
|
|