Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Overview

Simple printing API. The module currently only provides an API to call and a method of choosing the default printer for OpenMRS. No additional functionality is included.

Setup

In your module you must indicate that the printing module is required. In config.xml put:

<require_modules>
     <require_module>org.openmrs.module.printing</require_module>
</require_modules>

Example Usage

Class printingServiceClass = getClass().getClassLoader().loadClass("org.openmrs.module.printing.PrintingService");
PrintingService printingService = (PrintingService)Context.getService(printingServiceClass);
ByteArrayOutputStream out = new ByteArrayOutputStream();

... write to 'out' ...

printingService.addPrintJob(out.toByteArray(), true /* interactive */ ));

interactive mode will pop up a java print dialog box that the user must click through to continue printing.

Download

Download Module

Developers

?Unlicensed user

  • No labels