Print.Preview.property

Description

Properties that control the print preview of a DataWindow.

Applies to

DataWindows

Syntax

DataWindow .NET dot notation:

dw_control.PrintProperties.property

Describe and Modify argument:

"DataWindow.Print.Preview.property { = value }"

DataWindowSyntaxFromSql:

DataWindow ( Print.Preview.property = value )

Parameter

Description

property

A property for print preview. Properties and their settings are listed in the table below.

value

The value to be assigned to the property. Value cannot be a DataWindow expression.

Property for Print.Preview

Value

Buttons

Whether buttons display in print preview. Values are:

  • Yes – Buttons are displayed.

  • No – (Default) Buttons are not displayed.

Painter: Display Buttons – Print Preview.

Outline

Whether a blue line displays to show the location of the margins. Values are:

  • Yes – (Default) Margin outline is displayed.

  • No – Margin outline is not displayed.

Painter: Print Preview Shows Outline

Rulers

Whether the rulers display when the DataWindow object displays in preview mode:

  • Yes – Display the rulers.

  • No – (Default) Do not display the rulers.

You can view rulers in Preview mode in the DataWindow painter. With the Preview view selected, select File>Print Preview, then File>Print Preview Rulers. However, the setting is not used at runtime. To see rulers at runtime, set Print.Preview.Rulers in code..

Zoom

An integer indicating the zoom factor of the print preview. The default is 100%.

You can view different zoom percentages in Preview mode in the DataWindow painter. With the Preview view selected, select File>Print Preview, then File>Print Preview Zoom. However, the setting is not used at runtime. To change the zoom factor at runtime, set Print.Preview.Zoom in code..

Usage


In the painter

Select the DataWindow by deselecting all controls; then set values in the Properties view, Print Specifications tab.

In DataWindow .NET, you can use the PrintProperties class to set print properties using dot notation. Note that the names of some properties of the PrintProperties class differ from the names of the DataWindow object property, and some take a different value.

See the description of the PrintProperties class in the online Help in Visual Studio .NET for a complete list of Print.Preview properties.

Examples

Example 1

[Visual Basic]
setting = dw_1.Describe
		("DataWindow.Print.Preview.Buttons")

Example 2

dw_1.Modify("DataWindow.Print.Preview.Buttons = 'Yes'")

Example 3

dw_1.PrintProperties.ShowPreviewButtons = 'Yes'

Example 4

setting = dw_1.Describe
		("DataWindow.Print.Preview.Rulers")

Example 5

dw_1.Modify("DataWindow.Print.Preview.Rulers = 'Yes'")

Example 6

dw_1.PrintProperties.ShowPreviewRulers = 'Yes'

See also