Option to export/save report as PDF?

Is there a way to save the report as PDF as opposed to XPS file type?

I’m just wondering why the XPS file type is chosen as the default format since PDF format is more standardized ?

Its because XPS format is a windows feature so you do not have to install third party modules to view them.

1 Like

Technically you could use an action to start a .bat file and convert the file from xps to pdf on the file is saved event. This would require a simple command line converter app and actions/rules to support it.
The Actions and Rules would require setting up a Automation Command that fires the save file. You could even automate it and have it email the pdf to you.

But the most sensible way would be eventually for Emre to just add save to PDF option :smile:

You can use GhostXPS for this (http://www.ghostscript.com/download/gpcldnld.html).

Download GhostPCL GPL release, put the gxps folder in your sambapos folder, and then create a batch file like this in your sambapos folder (convert.bat):

@echo off
cls

set rSource=%1
set rTarget=%2

set gxpsLocation=“C:\SambaPOS3\gxps”

:: Delete previous rTarget
if exist %rTarget% del %rTarget%

C:
CD
CD “%gxpsLocation%”
gxps.exe -sDEVICE=pdfwrite -sOutputFile=%rTarget% -dNOPAUSE %rSource%

Create an action to save the report:

Create an action to do the conversion:


(change isHidden to True if you don’t want to see the conversion window)

Create an automation command to make a button to save the report:


(add a mapping and select under “visibility” where you want the button shown)

Create a rule to link the automation command with the actions created:


(add a standard mapping)

You will have to logout of sambapos and login again for this to work.

Can you show some before convert and after convert. I have been looking for a good open source conversion tool but 90% of them give horrible output.

I found a great tool that will convert it to .xls and it converts it spot on… but it costs 99.00 :frowning: I do not mind paying for software I just cant justify the price for convenience because I really do not NEED the conversion.

I can show you, but there’s hardly any data in my system, and I haven’t really tried any different reports, so it’s possible that the conversion is not so good, I have no idea. I’m not planning to use this option either, I’d rather use scripts to build custom reports (I can’t use V4 because of the language limitation), so I haven’t really tested this out much.
What report would you like to see?

After thinking about it. Do not bother I can just download and try it myself.