There are a number of commands to get the label length and width, but I recommend using the SGD class.
string length = Printer.SGD.GET("odometer.label_dot_length", connection);
string width = Printer.SGD.GET("ezpl.print_width", connection);
Keep in mind, the width is set by the system. There is no width sensor in most of our printers. The length is usually set by calibration using sensors built into the printer.
Thanks for your reply. I am able to get length and width through ZebraPrinterLinkOs setting list. Which way is better, SGD class or ZebraPrinterLinkOs?
There's also one thing that confuse me is when user change their roll (different size), and do the calibrate command on the printer, the printer is unable to detect the width. So how do user change the label width manually? I tried with window printer / printing preferences where we can set label width and height but its seem like not applied. However, it is applied when I changed it in ZebraDesigner/Label Setup Wizard.
I know that I can set label width programmatically. But is there any other way that user can do it by themselves?
Thank you for your time.
The width can be set using the Setup Utility, or by sending one of the print width command to the printer. The easiest way for a end user to do this if they are not printing using the driver, but have the printer connected over USB is to send the command using the driver "Send Command" feature. If they are not connected to a PC, we have an Android based Printer Setup app.