ScriptX Printing Samples

ScriptX.Services in the cloud, for On Premise Devices and for Windows PC are all designed to work with any evergreen browser and enable the same script code to control printing to be used in Internet Explorer, Chrome, Edge, Firefox, Safari and any modern browser.

Please visit the MeadCo main site for more information. We also have a samples site for ScriptX.Services which showcases the functionality available. For Internet Explorer, those samples require IE 11.

These ScriptX.Addon printing samples provide exemplar implementations and discussion of the techniques available for controlling the printing experience within Internet Explorer using ScriptX.Addon in a wide variety of interesting scenarios. We maintain these samples as examples and illustrations of how ScriptX.Addon v8.x with Internet Explorer 11 fully supports "legacy" content. Enterprise Modes and working with Enterprise Site List is fully supported. These samples allow you to also test this by use of DOCTYPE and docmode selections for the samples which will alter the HTML used, or by use of F12 Emulation settings.

Note: The first time you access a sample you may be asked to accept the version of the ScriptX.Addon software you chose; you must be logged on to your Microsoft Windows powered PC as an administrator to permit the installation. You may also be requested to accept this site's evaluation publishing license.

Setup

The samples are available:

Using your currently installed version [(Unknown)Discover
Using the latest test code [vNone available]
Using the latest hot fixes [vNone available]
Using the current release code [v8.3.0.4]
Using one of the other available codebases: v

Note that any currently installed version cannot be downgraded, only upgraded.

Open samples in:  this window,  a new window,  new window for each

You are using a Unknown browser. Please note that these samples require Internet Explorer on Windows PC.

Version: 4.3.3.16989, 20 August 2019 10:26

Basic

Illustrates the straightforward use of the freely distributable basic ScriptX printing functionality to set page headers and footers, paper orientation.

'Wide' Basic'

Illustrates the straightforward use of the freely distributable basic ScriptX printing functionality. The page to be printed is very wide - this sample illustrates the new 'Scale to fit' functionality that will be available as standard with IE7 and ScriptX makes available to IE5.5 and IE6 users. The sample also illustrates changing the template type in use.

No ScriptX Basic

Illustrates the simple page without ScriptX.

IE 7 Basic

Illustrates the simple page in an old document mode.

IE 7 Wrapped iFrame

Illustrates the simple page in an old document mode inside an iFrame.

ScriptX with frames

Provides a discussion of using ScriptX with framesets including printing of individual frames.

Note that the structure of the html document for this sample does not work with IE 10 or later standards mode so the document mode will be set to IE9 standards mode in these cases.

Always IE 7 Template

Illustrates the use of the freely distributable ScriptX printing component to provide the IE 7 printing experience on all versions of IE from v5.5 onwards. No scripting is used to alter headers and footers etc.

Header and Footer Font

Illustrates scripted control of the font used to print the document header and footer. User/scripted defined fonts for headers and footers requires Internet Explorer 8 or later and ScriptX 6.5.439 or later.

ScriptX Installed Version Information

Illustrates how to obtain the version of ScriptX installed on a machine - this sample will not attempt to install a new version of ScriptX or upgrade any current installation.

Main Features

Advanced

Illustrates the typical use of ScriptX advanced printing functionality for which a publishing license is required.

Techie

An all-in-one technical example illustrating the most advanced use of licensed ScriptX functionality.

Reports

Provides a discussion of printing customised documents and reports with ScriptX and a number of samples of differing techniques. A mix of free and licensed functionality is used; the licensed functions provide an improved user experience..

Printer connections (requires v7.1 or later)

AddPrinterConnection and DeletePrinterConnection allow connections to be made to printers that are shared on the network but may not be in the users installed devices.

Printer control

Illustrates the use of the printerControl, Jobs and Job objects.

Direct (raw) printing (requires v6.3.436 or later)

Discusses sending data directly to the printer in scenarios such as sending ZBL commands to a Zebra Label printer or control code sequences to label printers.

Note: Direct printing is a cost-option which can be enabled on a 'standard' client-side license for an additional fee of $500.

Printing PDF Files (v7.1 or later)

Discusses printing of Adobe Acroobat PDF files using the new features available in ScriptX Corporate Edition 7.1 and later.

Note: Enhanced PDF printing is a cost-option which can be enabled on a 'standard' client-side license for an additional fee of $500.

Print client side generated HTML

Illustrates creating an html document on the client as a javascript string and then printing that html.

PrintHTML callbacks (requires v7 or later)

The PrintHTML API provides for queueing and printing of html documents in the background. ScriptX 7 and later adds the PrintHTMLEx API that provides callbacks on the progress of each job, allowing monitoring and error checking.

Working with frames

Frame (iframe) preview

The 'Wide' Basic sample but licensed, so conferring the ability to preview iframed content. This requires the use of the IE 7 style template.

ScriptX with frames

Provides a discussion of using ScriptX with framesets including printing of individual frames. This sample also illustrates previewing a frame.

Note that the structure of the html document for this sample does not work with IE 10 or later standards mode so the document mode will be set to IE9 standards mode in these cases.

ScriptX within a frame in frameset

Provides a discussion of using ScriptX with framesets where a particular individual frame is to be printed/previewed and ScriptX is placed on the document within the frame rather than the top most frameset document. This sample includes using MaxiPT.

Please note that this sample does work with IE 10 and laters standards mode.

ScriptX within an iframe

Provides a discussion of using ScriptX where a particular individual iframe is to be printed/previewed and ScriptX is placed on the document within the (i)frame rather than the top most frameset document. This sample includes using MaxiPT.

Controlling margins, printing and previewing frames

In an international environment there may be a mixture of margin measurement units - this sample sets margins in the opposite units to your default illustrating that with ScriptX you gain control of the units for specifying measurements. This sample also illustrates the scaled to fit preview and printing of a frame.

Enhanced formatting (requires v7 or later, IE 8 or later)

Enhanced formatting provides for finer control over the headings and footers by allowing HTML snippets to be used, and for an enhanced page range specification.

Note: Enhanced formatting is a cost-option which can be enabled on a 'standard' client-side license for an additional fee of $500.

Headers and footers

Illustrates the use of multi-line HTML headers and footers.

Page ranges

This sample shows the use of enhanced page range specification; the ability to print arbitrary ranges of pages (rather than a single range) and print only odd, only even or both odd and even numbered pages.

Techie

An all-in-one sample by which you can explore the effect on output of each of the enhanced formatting options. This sample starts with example enhanced headers and footers filled in.

Blank Techie

An all-in-one sample by which you can explore the effect on output of each of the enhanced formatting options. This sample starts without any example data.

Queued printing (requires 7.0.18.1 or later)

This sample shows the use of enhanced formatting with the queued printing method printHTML().

Interactive report selection and dynamic enhanced formatting

A 'walk-thru' demo illustrating ScriptX Enhanced Formatting HTML header and (in this case, hidden) frame printing capabilties all wrapped in a modal dialog window.

Miscellaneous illustrations

Automating preview

Illustrates calling for a preview during the initialisation of the page taking the user straight to the preview from which they can then print.

Use of OwnQueue

Provides a discussion of the usage of the OwnQueue() method with the printHtml() method for printing reports.

ScriptX Events

ScriptX fires a number of events, such as when the user chooses print preview and when printing has completed. This short article illustrates each of these events.

Printing the selection or range of pages

Discusses the SetPageRange() method that provides for printing only the selected content, or a range of pages.

Preview Zoom (requires ScriptX 6.3.435 or later)

Illustrates setting a custom zoom factor for print preview.

Print scaling (requires ScriptX 6.3.435 or later)

Illustrates specifying the print scaling to use. This requires the IE 7 style template and enables overriding the default of 'scale to fit'/100%.

Determining the number of pages to be printed (requires v7 or later)

Illustrates obtaining the totalPrintPages property.

Persistent unique identifier (requires ScriptX 7.1 or later)

Illustrates using the persistent Unique identifier.

Please note that the MaxiPT samples always use Quirk-mode, standards modes are not supported.

Feature Set #1 - scripted control

Illustrates the use of HTML headers and footers and all other functions of MaxiPT Feature Set #1. The required settings are made via on page script.

Feature Set #1 - control by css

Illustrates the use of HTML headers and footers and all other functions of MaxiPT Feature Set #1. The required settings are made by css style rules.

Optimal layout

Illustrates the use of the Optimal Layout function of MaxiPT Feature Set #2.

Frame preview

Illustrates the use of the Frame preview function of MaxiPT Feature Set #2 - please note that this facility is now also available as a licensed function when using the IE 7 style template with ScriptX.

Scaling

Illustrates the use of the Scaled printing function of MaxiPT Feature Set #2.

Frames

Illustrates the MaxiPT template being used with frames and allows comparison with the 'standard' templates.

ScriptX within a frame

Provides a discussion of using ScriptX with framesets where a particular individual frame is to be printed/previewed and ScriptX is placed on the document within the frame rather than the top most frameset document. This sample includes using the standard templates, MaxiPT is the default.

These samples are specific to Internet Explorer 9 or later and require v6.6 or later of ScriptX.