Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Label printing integration (NiceWatch middleware and ActiveX programming interface)

Moderators: Georges, milos, NiceLabel Support Team

Post Reply
margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Tue Nov 05, 2019 6:12 pm

Hi guys, I need your help. I' m writing a WPF application to print labels on different printers using sdk for 17.3 rel . When I try to grab the printer status following the simpleprintasync sample it gaves spool and print completed immediately but printer (Sato CL4NX nicedriver) is still printing. How can I take the notification when the printer really ends printing? Another problem is with a second printer, Zebra S4M 203dpi ZPL usb. I try using driver for 200dpi and 300dpi (203dpi is not available) but it doesn't work. If I use zebra native driver it works well. Can you please help me?

Thanks

margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Wed Nov 06, 2019 9:08 pm

Any idea? Please help me, I need to fix these issues

User avatar
Mytch
NiceLabel Support
NiceLabel Support
Posts: 103
Joined: Fri Jul 13, 2018 10:26 pm
Location: Milwaukee, Wisconsin
Contact:

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by Mytch » Thu Nov 07, 2019 7:44 pm

margy82,

Firstly, please ensure you have the latest NiceLabel printer driver installed and configured in the label file wish you desire to print:
https://www.nicelabel.com/downloads/printer-drivers

Also be sure that "bidirectional support" is enabled in Printer Properties > Ports for this driver, if supported. If using a network printer, be sure that the port is defined as "Advanced Port Monitor" instead of Standard TCP/IP. USB ports are also supporting bidirectional communication.

Printer statuses reporting will vary - there is no expectation that all systems will report their status in the same manner.

Regards,
Mytch

margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Fri Nov 08, 2019 8:05 am

Mytch wrote:
Thu Nov 07, 2019 7:44 pm
margy82,

Firstly, please ensure you have the latest NiceLabel printer driver installed and configured in the label file wish you desire to print:
https://www.nicelabel.com/downloads/printer-drivers

Also be sure that "bidirectional support" is enabled in Printer Properties > Ports for this driver, if supported. If using a network printer, be sure that the port is defined as "Advanced Port Monitor" instead of Standard TCP/IP. USB ports are also supporting bidirectional communication.

Printer statuses vary by manufacturer and model of the hardware - there is no expectation that all printers will report their status in the same manner.

Regards,
Mytch
Hi Mytch, thanks for your reply but it definitly doesn' t work. All settings you write in your post are ok (see attachments) but it continues to give immediatly "Printed" also if printer is working. It seems that it reads data from Windows 32 spooler and not from the driver. Any idea?

Thanks
Attachments
3.JPG
3.JPG (68.71 KiB) Viewed 253 times
2.JPG
2.JPG (54.36 KiB) Viewed 253 times
1.JPG
1.JPG (58.37 KiB) Viewed 253 times

User avatar
Mytch
NiceLabel Support
NiceLabel Support
Posts: 103
Joined: Fri Jul 13, 2018 10:26 pm
Location: Milwaukee, Wisconsin
Contact:

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by Mytch » Fri Nov 08, 2019 4:50 pm

margy82,

Correct me if I'm wrong, but you are basing an application on SimpleAsyncPrintSample. This sample is using NiceLabel.SDK.SpoolJobStatus method to provide status updates. Here are the available status messages per SDK Reference Guide:
screenshot_21.jpg
screenshot_21.jpg (63.87 KiB) Viewed 238 times
"Printed" status means print job successfully sent to the printer in this case. Again, the behavior will vary depending on system and printer. I think your expectation is to get latest status directly from the printer, which this sample is not doing. The sample is simply interfacing with spooler to provide simple status and demonstrate asynchronous printing.

Regards,
Mytch

margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Fri Nov 08, 2019 7:15 pm

Exactly. I' m doing tests directly from simpleprintasyns sample. In the WPF application that I'm writing I have a list of different label to print but before sending a print command I need to grab the Real time status from the printer to check if it is printing or idle. Not from windows spooler becouse it immediately send jobs to the printer and the status returned la immediately "printed".

Thanks

User avatar
Mytch
NiceLabel Support
NiceLabel Support
Posts: 103
Joined: Fri Jul 13, 2018 10:26 pm
Location: Milwaukee, Wisconsin
Contact:

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by Mytch » Fri Nov 08, 2019 9:13 pm

margy82,

The functionality you desire is already built into PowerForms and Automation Enterprise with the "Printer Status" action. Each printer has proprietary status messages, so it's not just a universal message all printers provide. NiceLabel Printer Drivers support reporting messages as shown below:
screenshot_17.jpg
screenshot_17.jpg (71.63 KiB) Viewed 229 times
As far as trying to implement similar functionality into your application, unfortunately, I do not have any advice here. I can tell you that the sample you're working with is for getting status updates from the spooler and there's no simple way to get the status info from the hardware using the API. You could request a new feature to implement NiceLabel driver status checking here:
viewforum.php?f=12

Maybe you can have Automation running TCP/IP trigger and send signal, which will trigger action to get printer status from defined printer, and then send back to your application via TCP. Perhaps someone else has a better method using API only.. but this sample is working as designed.

Regards,
Mytch

margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Fri Nov 08, 2019 10:53 pm

Ok I understand. So....using nicelabel drivers and checking for bidirectional communication I suppose is useless becouse the sdk API queries the windows 32 spooler. Not the driver. But the status of the windows 32 spooler is wrong. Almost it is non the Real printer status....

margy82
Enthusiast
Posts: 20
Joined: Sun Sep 11, 2016 6:14 pm

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by margy82 » Sun Dec 01, 2019 6:28 pm

Ok, I found the way. I need to use sdk of Zebra and Sato to connect to printers and ask through these API the Real time status of the printers using ZPL and SBPL commands or their methods. Now I have another issue. I tried to open different labels invoking OpenLabel() method of ILabel interface from different threads to speed up the loading phase but PrintEngine crash giving strange errors. Is OpenLabel method usable in parallels threads?

Thanks

User avatar
Mytch
NiceLabel Support
NiceLabel Support
Posts: 103
Joined: Fri Jul 13, 2018 10:26 pm
Location: Milwaukee, Wisconsin
Contact:

Re: Print/spool status and nicedriver for Zebra S4M 203dpi ZPL

Post by Mytch » Mon Dec 02, 2019 8:04 pm

margy82 wrote:
Sun Dec 01, 2019 6:28 pm
Ok, I found the way. I need to use sdk of Zebra and Sato to connect to printers and ask through these API the Real time status of the printers using ZPL and SBPL commands or their methods. Now I have another issue. I tried to open different labels invoking OpenLabel() method of ILabel interface from different threads to speed up the loading phase but PrintEngine crash giving strange errors. Is OpenLabel method usable in parallels threads?

Thanks
Hi,

Glad to hear you found a solution for real-time print status.

Off the top of my head, I don't see any issues with this, because NiceLabel SDK.NET is thread-safe and supports native multi-threaded printing (using async). Since this issue is fairly unrelated to the original, I recommend that you create a new topic about this issue and provide additional information. Such as what language is used, what method is used for multiple threads, excerpt of non-working code, received error message, etc. This will allow other users to provide input who may have experience with this scenario.

Regards,
Mytch

Post Reply