Documentation Index

Fetch the complete documentation index at: https://kb.lasernetgroup.com/llms.txt

Use this file to discover all available pages before exploring further.

Cloud Print Connector 1.2 Overview

Prev Next

The Lasernet Cloud Print Connector 1.2 includes the option to print LNEMF files.

The benefit of LNEMF files is that they make cloud printing printer-independent. The installation of different printer drivers (brands) on the Lasernet server is not required, as it was in the legacy version of the Lasernet Cloud Print Connector.

The following formats are supported through Cloud Print Connector:

Format

Description

PDF

Used when re-printing documents from the Lasernet Archive or when printing attachments.

RAW

When using the EMF-to-RAW (Cloud Print Driver) module in Lasernet. It requires the different printer drivers/brands to get installed on the Lasernet Server.

LNEMF (EMF)

Used when printing directly from the Form/Print-sheet and does not require the different printer drivers/brands to get installed at the Lasernet Server (printer independent).

Installation

Enabling the print process of the LNEMF files requires downloading and installing version 1.2 of the Lasernet Cloud Print Connector.

The Lasernet Cloud Print Connector can be downloaded with the help of the Download menu available on the Printers page (Lasernet > Setup > Lists > Printers).

Supported Printer Properties

Printer properties can be defined and passed to the Lasernet Cloud Print Connector through a Printing Contract. The supported printer properties are as follows:

  • FormName

  • Orientation (landscape or portrait)

  • PaperWidth

  • PaperHeight)

  • Scale

  • Copies

  • PaperSource (number, or a paper source, such as "Tray 1")

  • PrintQuality

  • ColorMode (color or monochrome)

  • DuplexMode (simplex, horizontal or vertical)

LNEMF

PDF

RAW

FromPage/ToPage

Supported [1]

Supported

Not supported [3]

PrinterSettings - Copies/duplex/PaperSource

Supported

Supported [2]

Not supported [4]

Follow me - WinPrintUserName/WinPrintNotifyName

Supported

Currently not supported [5]

Supported

[1] The printer supports it.

[2] The printer supports it, but it looks like the settings are only used for rendering and not actually being sent to the printer.

Example: if there are two copies, two prints are made. However, the printer only sees one copy.

[3] The printer requires that we either parse the RAW data, or Lasernet splits the commands into pages, for instance, create an LNRAW contract like LNEMF.

[4] The printer expects settings to be part of data (commands), so settings are ignored.

[5] Print job ID is not returned, so it requires additional work.

Lasernet Default Configuration Application

Our Lasernet Default configuration includes the setup for the Lasernet Cloud Print Connector. Details on this setup are described in this guide.

Global JobInfo EnableLNEMFPrinting

A global JobInfo EnableLNEMFPrinting on the Server determines whether RAW or LNEMF must be used for printing.

When using LNEMF (EMF) printing, the EMF to RAW module is skipped, and documents can get passed directly from a print sheet (Form) into the Azure Storage Printer (storage used by Cloud Print Connector).

The LNEMF document is encoded (Base64 Encode) before passing to the Azure Storage Printer output module.

Printer Contract

The Azure Storage Printer output module contains JobInfo xmlPrinterSettings in Pre JobInfos, which passes details on how the file should be printed.

  • xmlPrinterSettings: Printer properties such as the Orientation, Paperwidth, Paperheight, copies, etc. This JobInfo contains the Printing Contract values.

<PrinterSettings xmlns:a="http://schemas.microsoft.com/2003/10/Serialization/Arrays">


	<a:KeyValueOfstringstring>

		<a:Key>PaperSource</a:Key>
		<a:Value>#PaperSource#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>Copies</a:Key>
		<a:Value>#Copies#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>Orientation</a:Key>
		<a:Value>#Orientation#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

	<a:Key>PaperHeight</a:Key>

	<a:Value>#PaperHeight#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>PaperWidth</a:Key>
		<a:Value>#PaperWidth#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>PrintQuality</a:Key>
		<a:Value>#PrintQuality#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>ColorMode</a:Key>
		<a:Value>#ColorMode#</a:Value>

	</a:KeyValueOfstringstring>

	<a:KeyValueOfstringstring>

		<a:Key>DuplexMode</a:Key>
		<a:Value>#DuplexMode#</a:Value>

	</a:KeyValueOfstringstring>

</PrinterSettings>

For follow-me print (WinPrintNotifyName, WinPrintUserName),

<a:KeyValueOfstringstring>

	<a:Key>WinPrintNotifyName</a:Key>
	<a:Value># WinPrintNotifyName#</a:Value>

</a:KeyValueOfstringstring>

<a:KeyValueOfstringstring>

	<a:Key>WinPrintUserName</a:Key>
	<a:Value>#WinPrintUserName#</a:Value>

</a:KeyValueOfstringstring>

Scripts

EnableLNEMFPrinting is used within the Lasernet Connector functions script, function setOutParameters:

// Need to Base64 encode JobData when printing allowed LNEMF

else if ((prefix.toLowerCase()=='Output'.toLowerCase() ||

prefix.toLowerCase()=='CustomOutput'.toLowerCase()) &&

job.getJobInfo('PrinterType').toLowerCase() == 'Lasernet Cloud Print Connector'.toLowerCase()&&

job.getJobInfo('DataFormat').toLowerCase() == 'EMF'.toLowerCase() &&

job.getJobInfo('EnableLNEMFPrinting').toLowerCase() == 'Yes'.toLowerCase()) // when main file

{

                   if (job.getJobInfo(prefix+'JobDataEncoded').toLowerCase() != 'Yes'.toLowerCase())

                   {

                                      logger.logEvent(0, 'Base64 Encoding main');

                                      job.setJobData(Base64.encode(job.getJobData())); // double encoding?

                                      job.setJobInfo(prefix+'JobDataEncoded', 'Yes', true);

                   }

}

logger.logEvent(0, 'EnableLNEMFPrinting=' + job.getJobInfo('EnableLNEMFPrinting'));

// Setting document index to next

getSetIndex(prefix, documentIndex);

                  

    // Setting document index to next

    getSetIndex(prefix, documentIndex); 

}

Was this page helpful? Let us know at knowledgebase.feedback@lasernetgroup.com