.NET code to send ZPL to Zebra printers
问题 Is there a way to send ZPL (Zebra Programming Language) to a printer in .NET? I have the code to do this in Delphi, but it is not pretty and I would rather not try to recreate it in .NET as it is. 回答1: Take a look at this thread: Print ZPL codes to ZEBRA printer using PrintDocument class. Specifically the OP pick this function from the answers to the thread: [DllImport("kernel32.dll", SetLastError = true)] static extern SafeFileHandle CreateFile(string lpFileName, FileAccess dwDesiredAccess,