Share via


Print Template Reference

This section contains links that provide access to the object model exposed by the print preview behaviors.

Elements

Topic Contents
DeviceRect

Provides a container forLAYOUTRECTelements and other content in a print template.

HeaderFooter

Provides a tool so that a print template can convert header and footer formatting strings to formattedHTML.

LayoutRect

Creates a container element for document content in a print or print preview template.

TemplatePrinter

Provides a print template with access to page setup and printer settings and control over print jobs initiated from the template.

 

Objects

Topic Contents
dialogArguments

Provides a print template with access to thedialogArgumentsproperties passed to the print preview dialog window.

 

Properties

Topic Contents
__IE_ActiveFrame

Retrieves the index of the active frame in the frames collection.

__IE_BaseLineScale

Retrieves an integer specifying the font size of the print template.

__IE_BrowseDocument

Retrieves thedocumentobject of the page being printed or print-previewed.

__IE_ContentDocumentUrl

Retrieves a string specifying theURLof a temporary copy of the source document for the print template.

__IE_ContentSelectionUrl

Retrieves a string specifying theURLof a temporary .htm file containing the current selection in the browser.

__IE_DisplayUrl

Retrieves a string that specifies theURLof the document.

__IE_FooterString

Retrieves a string specifying the footer string from thePage Setupdialog box.

__IE_HeaderString

Retrieves a string specifying the header string from thePage Setupdialog box.

__IE_OutlookHeader

Retrieves a string specifying theMicrosoft Outlookheader string.

__IE_PrinterCMD_Device

Retrieves a string specifying the printer device driver if one was specifcied by the caller.

__IE_PrinterCmd_DevMode

Retrieves aDEVMODEstructure that contains information about the device initialization and environment of a printer.

__IE_PrinterCmd_DevNames

Retrieves aDEVNAMESstructure that contains strings which identify the driver, device, and output port names for a printer.

__IE_PrinterCMD_Port

Retrieves a string specifying the printer port if one was specified by the caller.

__IE_PrinterCMD_Printer

Retrieves a string specifying the printer name.

__IE_PrintType

Retrieves a string specifying whether a print template should prompt the user with the Print dialog box, with the Print Preview dialog box, or not prompt the user at all.

__IE_TemplateUrl

Retrieves a string specifying theURLof the print template.

__IE_TemporaryFiles

Retrieves a reference to a list of temporary file names saved from this document.

__IE_uPrintFlags

Retrieves a print flag value.

allLinkedDocuments

Sets or retrieves whether all documents linked to in the current document are printed with the current print job.

collate

Sets or retrieves whether the pages of a document are collated when printed.

contentDocument

Retrieves thedocumentobject of the page being printed or print-previewed.

contentOverflow

Retrieves a value that indicates whether the document contains additional content after processing the current LayoutRect object.

contentSrc

Sets or retrieves the content source for aLAYOUTRECTelement in a print template.

copies

Sets or retrieves how many copies of the document to print.

currentPage

Sets or retrieves a Boolean value indicating whether the print current page option is checked.

currentPageAvail

Sets or retrieves a Boolean value indicating whether the print current page option should be enabled in the print dialog box.

dateLong

Sets or retrieves the current date in long format.

dateShort

Sets or retrieves the current date in short format.

duplex

Retrieves a Boolean value indicating whether double-sided printing is active.

font

This method gets or sets the font properties for the header and footer.

footer

Sets or retrieves the footer formatting string from thePage Setupdialog box.

frameActive

Sets or retrieves a value that indicates whether the option button labeledOnly the selected framein thePrint framessection of thePrintdialog box is selected.

frameActiveEnabled

Enables or disables the radio button labeledOnly the selected framein thePrint framessection of thePrintdialog box.

frameAsShown

Sets or retrieves whether the document's frames are printed exactly as they appear on the screen.

framesetDocument

Sets or retrieves whether all the documents in the frameset are printed.

header

Sets or retrieves the header formatting string from thePage Setupdialog box.

headerFooterFont

Sets or retrieves a combination of strings that define font properties of the header and footer.

honorPageBreaks

Not implemented.

honorPageRules

Not implemented.

htmlFoot

Retrieves the HTML representation of the footer, as specified by the footer formatting string entered in thetextFootproperty of theHeaderFooterbehavior.

htmlHead

Retrieves the HTML representation of the header, as specified by the header formatting string entered in thetextHeadproperty of theHeaderFooterbehavior.

marginBottom

Sets or retrieves the bottom margin of the document to be printed.

marginLeft

Sets or retrieves the left margin of the document to be printed.

marginRight

Sets or retrieves the right margin of the document to be printed.

marginTop

Sets or retrieves the top margin of the document to be printed.

MEDIA

Sets or retrieves whether the document will be printed at the highest possible resolution.

nextRect

Sets or retrieves the identifier of the nextLayoutRectelement used to format the document.

orientation

Sets or retrieves the printing orientation for the current printer.

page

Sets or retrieves the page number that theHeaderFooterbehavior uses when generating HTML for headers and footers.

pageFrom

Sets or retrieves the first page in the document to be printed.

pageHeight

Retrieves the current height of a page on the printer.

pageTo

Sets or retrieves the last page in the document to be printed.

pageTotal

Sets or retrieves the page total that theHeaderFooterbehavior uses when generating HTML for headers and footers.

pageWidth

Retrieves the current width of a page on the printer.

selectedPages

Sets or retrieves whether a selected range of pages is printed, rather than the whole document.

selection

Sets or retrieves whether the selected portion of the document is the only part to be printed.

selectionEnabled

Enables or disables theSelectionradio button on thePrintdialog box.

tableOfLinks

Sets or retrieves whether to print a table of links as part of the current print job.

textFoot

Sets or retrieves the control string used by theHeaderFooterbehavior to generate HTML for the footer.

textHead

Sets or retrieves the control string used by theHeaderFooterbehavior to generate HTML for the header.

timeLong

Sets or retrieves the current time in long format.

timeShort

Sets or retrieves the current time in short format.

title

Sets or retrieves the title of the document currently being printed or print-previewed.

unprintableBottom

Retrieves the size of the bottom unprintable margin for the current printer.

unprintableLeft

Retrieves the size of the left unprintable margin for the current printer.

unprintableRight

Retrieves the size of the right unprintable margin for the current printer.

unprintableTop

Retrieves the size of the top unprintable margin for the current printer.

url

Sets or retrieves theURLof the document currently being printed or print-previewed.

usePrinterCopyCollate

Sets or retrieves a value that indicates whether the printer copy/collate feature is enabled.

 

Methods

Topic Contents
deviceSupports

Checks whether the printer supports a specified feature.

ensurePrintDialogDefaults

Not supported.

getPageMarginBottom

Returns size of bottom margin from a specified @page rule and page dimensions.

getPageMarginBottomImportant

Retrieves whether the bottom margin of the specified @page rule is marked as!important.

getPageMarginLeft

Returns size of left margin from a specified @page rule and page dimensions.

getPageMarginLeftImportant

Retrieves whether the left margin of the specified @page rule is marked as!important.

getPageMarginRight

Returns size of right margin from a specified @page rule and page dimensions.

getPageMarginRightImportant

Retrieves whether the right margin of the specified @page rule is marked as!important.

getPageMarginTop

Returns size of top margin from a specified @page rule and page dimensions.

getPageMarginTopImportant

Retrieves whether the top margin of the specified @page rule is marked as!important.

printBlankPage

Prints a blank page.

printNonNative

Sends a non-HTML document, such as aMicrosoft Worddocument, to the printer.

printNonNativeFrames

Sends a non-HTML document, such as aWorddocument, to the printer from a page containing frames.

printPage

Sends a page, as defined by aDeviceRect, to the printer.

showPageSetupDialog

Displays the Page Setup dialog box.

showPrintDialog

Displays the Print dialog box.

startDoc

Uses the current print template to start a print job.

stopDoc

Ends the current print job.

updatePageStatus

Indicates the status of a print job.

 

Events

Topic Contents
onlayoutcomplete

Fires when the print or print preview layout process finishes filling the current LayoutRect object with content from the source document.

 

Additionally, interfaces are available to access print template functionality in C++.

Interfaces

Topic Contents
IHeaderFooter

Implements print template properties.

IHeaderFooter2

Extends IHeaderFooter.

ITemplatePrinter

Provides a print template with access to page setup and printer settings, as well as control over print jobs initiated from the template.

ITemplatePrinter2

Provides a print template with access to page setup and printer settings, as well as control over print jobs initiated from the template.

ITemplatePrinter3

Extends ITemplatePrinter2 to retrieve author-specified page margins and to modify the font used for page header and footer.

 

Objects

Topic Contents
CTemplatePrinter

Provides access to the ITemplatePrinter2 interface.