Share via


Application Members (Publisher)

Represents the Microsoft Publisher application. The Application object includes properties and methods that return top-level objects. For example, the ActiveDocument property returns a Document object.

Methods

Name

Description

CentimetersToPoints

Converts a measurement from centimeters to points (1 cm = 28.35 points). Returns the converted measurement as a Single.

ChangeFileOpenDirectory

Sets the folder in which Microsoft Publisher searches for documents. The specified folder's contents are listed the next time the Open Publication dialog box (File menu) is displayed.

EmusToPoints

Converts a measurement from emus to points (12700 emus = 1 point). Returns the converted measurement as a Single.

Help

Displays online Help information.

InchesToPoints

Converts a measurement from inches to points (1 inch = 72 points). Returns the converted measurement as a Single.

IsValidObject

Determines whether the specified object variable references a valid object and returns a Boolean value: True if the specified variable that references an object is valid, False if the object referenced by the variable has been deleted.

LinesToPoints

Converts a measurement from lines to points (1 line = 12 points). Returns the converted measurement as a Single.

MillimetersToPoints

Converts a measurement from millimeters to points (1 mm = 2.835 points). Returns the converted measurement as a Single.

NewDocument

Returns a Document object that represents a new publication.

Open

Returns a Document object that represents the newly opened publication.

PicasToPoints

Converts a measurement from picas to points (1 pica = 12 points). Returns the converted measurement as a Single.

PixelsToPoints

Converts a measurement from pixels to points (1 pixel = 0.75 points). Returns the converted measurement as a Single.

PointsToCentimeters

Converts a measurement from points to centimeters (1 cm = 28.35 points). Returns the converted measurement as a Single.

PointsToEmus

Converts a measurement from points to emus (12700 emus = 1 point). Returns the converted measurement as a Single.

PointsToInches

Converts a measurement from points to inches (1 in = 72 points). Returns the converted measurement as a Single.

PointsToLines

Converts a measurement from points to lines (1 line = 12 points). Returns the converted measurement as a Single.

PointsToMillimeters

Converts a measurement from points to millimeters (1 mm = 2.835 points). Returns the converted measurement as a Single.

PointsToPicas

Converts a measurement from points to picas (1 pica = 12 points). Returns the converted measurement as a Single.

PointsToPixels

Converts a measurement from points to pixels (1 pixel = 0.75 points). Returns the converted measurement as a Single.

PointsToTwips

Converts a measurement from points to twips (20 twips = 1 point). Returns the converted measurement as a Single.

Quit

Quits Microsoft Publisher. This is equivalent to clicking Exit on the File menu.

ShowWizardCatalog

Displays the Publication Types catalog for the wizard of the specified type.

TwipsToPoints

Converts a measurement from twips to points (20 twips = 1 point). Returns the converted measurement as a Single.

Properties

Name

Description

ActiveDocument

Returns a Document object that represents the active publication. If there are no documents open, an error occurs.

ActiveWindow

Returns a Window object that represents the window with the focus. Because Microsoft Publisher only has one window, there is only one Window object to return.

Application

Used without an object qualifier, this property returns an Application object that represents the current instance of Publisher. Used with an object qualifier, this property returns an Application object that represents the creator of the specified object. When used with an OLE Automation object, it returns the object's application.

Assistance

Gets a reference to the Microsoft Office (MSO) IAssistance object, which provides a means for developers to create a customized Help experience for users within Microsoft Office. Read-only.

AutomationSecurity

Specifies the security mode that Microsoft Publisher uses when programmatically opening files. Read/write.

Build

Returns a Long that represents the Microsoft Publisher build number. Read-only.

ColorSchemes

Returns a ColorSchemes collection that represents the color schemes available.

COMAddIns

Returns a COMAddIns collection that represents a reference to the Component Object Model (COM) add-ins currently loaded in Microsoft Publisher.

CommandBars

Sets or returns a CommandBars collection that represents the menu bar and all the toolbars in Microsoft Publisher.

Documents

Returns a Documents collection that represents all open publications. Read-only.

FileDialog

Returns a FileDialog object that represents a single instance of a file dialog box.

InsertBarcodeVisible

Determines whether Add a postal bar code is available under More Items on the Mail Merge and Catalog Merge task panes in the Microsoft Publisher user interface (UI); and whether Add postal bar codes is available under Prepare for Mailing on the Publisher Tasks task pane in the Publisher UI. Read/write.

InstalledPrinters

Returns an InstalledPrinters collection that represents the names of all the printers installed on the computer and to which Microsoft Publisher can print the publication. Read-only.

Language

Returns a Long that represents the language selected for the Microsoft Publisher user interface. Read-only.

Name

Returns a String value indicating the name of the specified object. Read-only.

OfficeDataSourceObject

Returns an OfficeDataSourceObject object representing the data source in a mail merge or catalog merge operation. Read-only.

Options

Returns an Options object that represents application settings you can set in Microsoft Publisher.

Parent

Returns an object that represents the parent object of the specified object. For example, for a TextFrame object, returns a Shape object representing the parent shape of the text frame. Read-only.

Path

Returns a String indicating the full path to the file of the saved active publication, not including the last separator or file name.

PathSeparator

Returns a String that represents the character used to separate folder names. Read-only.

PrintPreview

True to display in Print Preview the publication in the current view. Read/write Boolean.

ProductCode

Returns a String indicating the Microsoft Publisher globally unique identifier (GUID). Read-only.

ScreenUpdating

Returns or sets a Boolean indicating whether Microsoft Publisher refreshes the screen display during run time; True to refresh the screen display. Read/write.

Selection

Returns a Selection object that represents a selected range or the cursor.

ShowFollowUpCustom

Gets or sets the string, if any, that appears as the fourth item under Prepare to follow-up on this mailing on the third Mail Merge task pane in the Microsoft Publisher user interface. Read/write.

SnapToGuides

True for Microsoft Publisher to use the guides to align objects on a page in a publication. Read/write Boolean.

SnapToObjects

True for Microsoft Publisher to use objects on a page to line up other objects. Read/write Boolean.

TemplateFolderPath

Returns a String that represents the location where Microsoft Publisher templates are stored. Read-only.

ValidateAddressVisible

Determines whether Validate addresses is available under Refine recipients in the Mail Merge Recipients dialog box in the Microsoft Publisher user interface (UI); and whether Validate addresses is available under Prepare for Mailing on the Publisher Tasks task pane in the Publisher UI. Read/write.

Version

Returns a String indicating the version number of the currently-installed copy of Microsoft Publisher. Read-only.

WebOptions

Returns a WebOptions object, which represents the properties of Web publications. Read-only.

WizardCatalogVisible

Returns or sets a Boolean indicating whether the Wizard Catalog is visible. Read/write.

Events

Name

Description

AfterPrint

Fires after all variables and fields print.

BeforePrint

Occurs before the publication is printed or previewed. .

DocumentBeforeClose

Occurs immediately before any open document closes.

DocumentOpen

Occurs when opening a document.

HideCatalogUI

Occurs when the catalog of publication wizards is hidden in the Microsoft Publisher user interface.

MailMergeAfterMerge

Occurs after all records in a mail merge have merged successfully.

MailMergeAfterRecordMerge

Occurs after each record in the data source successfully merges in a mail merge.

MailMergeBeforeMerge

Occurs when a merge is executed before any records in a mail merge have merged.

MailMergeBeforeRecordMerge

Occurs as a merge is executed for the individual records in a merge.

MailMergeDataSourceLoad

Occurs when the data source is loaded for a mail merge.

MailMergeDataSourceValidate

Occurs when a user performs address verification by clicking Validate in the Mail Merge Recipients dialog box.

MailMergeGenerateBarcode

Occurs when Microsoft Publisher requires data to generate barcodes in a mail-merge publication, in particular when the mail-merge recipient list changes.

MailMergeInsertBarcode

Occurs when the user issues the command to insert postal barcodes into a mail-merge publication, either in the Microsoft Publisher user interface (UI), or programmatically.

MailMergeRecipientListClose

Fires when the user closes the Mail Merge Recipients dialog box. (From the Mail Merge or E-mail Merge task pane, click Edit Recipient List). Also fires when the user closes the Catalog Merge Product List dialog box, which opens when the user clicks Edit Product List in the Catalog Merge task pane.

MailMergeWizardFollowUpCustom

Fires when the string that appears as the fourth item under Prepare to follow-up on this mailing on the third Mail Merge task pane in the Microsoft Publisher user interface is clicked.

MailMergeWizardStateChange

Occurs when a user changes from a specified step to a specified step in the Mail Merge Wizard.

NewDocument

Occurs when a new publication is created.

Quit

Occurs when the user exits Microsoft Publisher.

ShowCatalogUI

Fires when the catalog of publication wizards is displayed in the Microsoft Publisher user interface.

WindowActivate

Occurs when the application window is activated.

WindowDeactivate

Occurs when the application window is deactivated.

WindowPageChange

Occurs when switching the view from one page to another page in a publication.