Printing to a Zebra thermal printer with .Net

hx009

Senior member
Nov 26, 1999
989
0
0
I know this is probably a long shot and I won't get any responses, but I'm going to ask anyways because I'm going out of my mind here. I have a C# application that prints labels out to a Zebra TLP 2844-Z thermal printer (well, it's supposed to anyways). The program does a PrintDocument.Print() to the default printer (the Zebra). In fact, it's practically stock code from Microsoft for printing. The problem is that the printer flat out ignores this. I have troubleshot the following:

- Opened the Windows printer queue, and actually watched the job show up and disappear as if everything is OK
- Set the printer to debug communications mode and actually see the raw data hit the printer
- Completely blown away a machine, attached the printer (LPT1), loaded XP, put a fresh copy of the Zebra driver, same result

What is absolutely worst is that any other program in Windows prints to it just fine on three different machines... Word, Notepad, Excel, Internet Explorer. The one thing I did read about was that the driver supposedly converts everything to Zebra's "ZPL" language. When Windows applications print, I see the ^XA (start printing) and ^XZ (stop printing) in the debug output of the printer. However, when I print from C#, I never see the commands. How this is even possible considering I'm using the exact same driver are beyond me.

p.s. I have read online about people writing directly to Zebra printers using this Microsoft article. That should not be necessary when using the Zebra Windows print driver. It is also a complete PITA when on one label you have 3+ different fonts, graphics, and two or more paragraphs of text.

I guess what I'm asking if anyone here has had experience with these printers and the .Net framework, and if so what advice you may have?
 

apoppin

Lifer
Mar 9, 2000
34,890
1
0
alienbabeltech.com
i do have a Zebra Stripe printer and occasionally i get into trouble . . . [i use Label Matriix]

try Zebra's tech support . . . it is pretty good.

also, does your printer have enough RAM to do what you are requesting?
 

hx009

Senior member
Nov 26, 1999
989
0
0
Thanks for all the replies.

As it turns out, the latest universal driver posted on their website has a known bug that causes it to drop or mangle print commands from the .NET framework. A fixed driver is in beta right now. I just wish they had made this bug known when I downloaded the latest driver a week ago!
 

WannaFly

Platinum Member
Jan 14, 2003
2,811
1
0
For what its worth...
I used VB.NET to print to a mobile zebra printer via bluetooth, I had to use a COM port and send raw text to it in zebras ZPL (Zebra Programming Language) to print. You can download the programming guide from their site.

 

hx009

Senior member
Nov 26, 1999
989
0
0
Originally posted by: WannaFly
For what its worth...
I used VB.NET to print to a mobile zebra printer via bluetooth, I had to use a COM port and send raw text to it in zebras ZPL (Zebra Programming Language) to print. You can download the programming guide from their site.

I did get it to work just fine with the Windows driver. However, I do have a question for you: Do you get shifting when printing? What I mean is, when I print something at 100,100 (X,Y), the output is inconsistant from label to label. I can send one job of 40 labels with an X dead center on the label, and I pretty much will get some shifted left, some right, up, down, etc.
 

LiLithTecH

Diamond Member
Jul 28, 2002
3,105
0
0
When you install the driver, are you selecting "use Printer Settings"?

What Model Zebra?
110, 140, 170 series has an manual adjustment you can make to stop the skewing.
 

hx009

Senior member
Nov 26, 1999
989
0
0
Originally posted by: LiLithTecH
When you install the driver, are you selecting "use Printer Settings"?

What Model Zebra?
110, 140, 170 series has an manual adjustment you can make to stop the skewing.

Yes, the driver is set to "use Printer Settings". I've done calibration after calibration and still get inconsistant results. I did actually trace the problem down to having to baby the installation of the label spool (its heavy stock and must be put in gently to prevent shifting). However, even still yet I'm getting text missing from label to label. I'm starting to think their driver is just plain garbage.
 

LiLithTecH

Diamond Member
Jul 28, 2002
3,105
0
0
Originally posted by: hx009 However, even still yet I'm getting text missing from label to label.

If it is consistently in the same location, try adding a little more pressure to the head
in the area of the missing text.

The adjustment for the skewing is done by loosening two screws, then adjusting
the head alignment (tilt left or right) position.