Appendix B – Sample Programs
154
Class Series Programmer’s Manual
VB Application to Send RAW Data via a Windows Printer Driver
This is a sample Visual Basic program that checks for any printer driver attached to “LPT1”. If one is
installed then a DPL file can be printed via the print driver. **Note that this does not have to be a
Datamax DPL print driver. DPL is created by the application and sent to LPT1.
To begin, a global variable called SelPrinter must be defined as a string. Then use the following code
to create a .frm file.
VERSION 5.00
Object = “{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0”;
“comdlg32.ocx”
Begin VB.Form Form1
Caption = “Form1”
ClientHeight = 1290
ClientLeft = 165
ClientTop = 735
ClientWidth = 3750
LinkTopic = “Form1”
MaxButton = 0 ‘False
MinButton = 0 ‘False
ScaleHeight = 1290
ScaleWidth = 3750
StartUpPosition = 3 ‘Windows Default
Begin MSComDlg.CommonDialog CommonDialog1
Left = 1635
Top = 765
_ExtentX = 847
_ExtentY = 847
_Version = 393216
End
Begin VB.CommandButton cmdClose
Cancel = -1 ‘True
Caption = “Close”
Height = 372
Left = 2400
TabIndex = 3
Top = 735
Width = 972
End
Begin VB.CommandButton cmdStoreImage
Caption = “Print”
Default = -1 ‘True
Height = 372
Left = 240
TabIndex = 2
Top = 735
Width = 972
End
Begin VB.TextBox txtFile
Height = 288
Summary of Contents for A-Class A-4310
Page 2: ......
Page 4: ......
Page 15: ...xi Appendix V 281 Bar Code Symbology Information Resources 281 Glossary 283...
Page 16: ...xii...
Page 30: ...Immediate Command Functions 14 Class Series Programmer s Manual...
Page 52: ...System Level Command Functions 36 Class Series Programmer s Manual...
Page 144: ...Label Formatting Command Functions 128 Class Series Programmer s Manual...
Page 162: ...Generating Label Formats 146 Class Series Programmer s Manual...
Page 182: ...Appendix D Reset Codes 166 Class Series Programmer s Manual...
Page 192: ...Appendix E Single Byte Symbol Sets 176 Class Series Programmer s Manual...
Page 236: ...Appendix G Barcode Details 220 Class Series Programmer s Manual...
Page 242: ...Appendix I Symbol Sets and Character Maps 226 Class Series Programmer s Manual...
Page 272: ...Appendix P UPC A and EAN 13 256 Class Series Programmer s Manual...
Page 282: ...Appendix R Plug and Play IDs 266 Class Series Programmer s Manual...
Page 296: ...Appendix U WiFi Region Country Codes 280 Class Series Programmer s Manual...
Page 302: ...Glossary 286 Class Series Programmer s Manual...