Vinay Kumar · Jun 19, 2020

How to Print Barcode on device through cache object Scripting


i am using Healthshare 2017.2 version with Trakcare 2018. how to generate & print barcode from cache object scripting in this version?


1 5 274 5


Hi Vinay,

Generally you write direct to device.

You need to know the language that the printer works.

A common used printer is Zebra that has a proprietary language called ZPL:

Healthshare documentation:

After you setup the device  you need to use then:

Hi Cristiano,

I am able to write the data on device directly from cache . I don't wan't to print barcode on barcode (zebra) printer. I want to print on A4 size paper from lazer printer through cups printing.

Hi Vinay,

In this case You need to write the postscript to the printer.

Maybe this project can help you:

Like Stephen suggested, but without using ZEN Reports, you can  use the the library Barcode4j:, (this library is used by the Zen Reports), you can use Java Gateway to call the library direct from your COS code.

Vinay, the typical approach to send to CUPS for TrakCare would be to use Zen reports or JReports. TrakCare's EPS print server can run the report automatically and send the result to the configured printer through CUPs.