Printing Logo to PDF Custom Printer?

For Automation purposes I need to automated the PDF file printing purposes, the only thing that “Custom Printer: Save To PDF Printer” doesn’t have is Printing the logo, Please add this feature!.

If you use an HTML template instead of one for ESC/POS printing you should be able to export your logo without issue.

If you look at RickH’s first post it should help you get started:

@Memo
Thanks but HTML printer doesn’t supports generating/automating output filename, I cannot bother my cashier peoples to save filename manually everytime the ticket being printed.

The pdf printer is very limited we don’t have much control over it. We have plans to add better support for these kind of features. I do not have an eta

1 Like

You might try saving it to a temporary file and utilizing ghostscript to convert to
PDF. I’ve used this for reports, but I imagine it might work with printer templates. See below:

1 Like

I see, I think for temporarily we need new “Save Ticket to File” Action Type, so we can work around the PDF Printer limitation by using Ghostscript.

Yes, thanks, for report I am also using “Save Report to File” & Ghostsciprt conversion, I was forgot to add that my request is also regarding automating Ticket export/printing to PDF file. Perhaps we need also “Save Ticket to File” Action type ?. If this being implemented does SambaPOS also will printing logo into XPS file?.

I don’t understand. Why don’t you just use a normal printer?

I am going paperless, so mostly all of customer’s ticket is going to their e-mail instead of normal paper printout. And I cannot bother my cashier to do manual pdf conversion on their own, imagine if it’s in rush hours. So I need to do it in automation command and using K.I.S.S principle.

Yeah, I totally missed that part of your post, sorry.

I found Emre’s original post when he added the Print to PDF custom printer and, as you’ve found out, it only supports text.

Having just finished searching for a C# PDF library, I can confirm that commercial PDF libraries are expensive. And the free ones are, well, lacking. Maybe .Net 6 will have something better but I’m not holding my breath.

If a logo is that important to you, the only think I can think of is some custom software that generates your PDF with the logo, or fills in a template then emails it. But then you’re running into the same problem Emre had with licensing cost for SambaPOS.

1 Like

Well, I didn’t read more, this might help you:

Select “Convert to Image” and see if it saves with the logo.

I’m pretty sure that feature doesn’t work.

If all else fails you could look at using a different pdf printer with more features. Bullzip seems to work well except for I can’t get it to use Roll Feed, so you can end up with extra white space. Kind of annoying.

1 Like

I haven’t tested it but looking at the error that was posted a little later in the thread, the error message contained “XCT” so I half-thought maybe it doesn’t work with the ESC/POS templates, but may work with HTML.

When I setup a hotel guest sign for bill and email receipt I didn’t like the pdf printer route as wasn’t reliable/consistent with generation times and didn’t want long delay to guarantee output.
What I did instead was setup a basic webapp/api on my website I setup for contactlesa guest checkin and made samba post a json array or ticket details which the website used to generate pdf with pdfdom framework and the website email to customer.
The advantage to this was all actions were positive ie, post to site, site processes and emails and returns response to samba.
So samba shows message to say it was emailed.
Was a bit of work but did work.
Just looked back and almost forgot, the actual signing bit is 2 step as they sign on their own device.
I did have a seccond flow for post pandemic where it uses the html oopup action to show the same page with esign on order tablet also.
But the email contains a pdf of the bill jig displayed on page.

1 Like