ComponentOne Preview Classic for WinForms: Preview Classic for WinForms Task-Based Help > Setting the Page Orientation

Setting the Page Orientation

To set the page orientation, set the PageSettings property. This property can be specified in the designer or in code.

In the Designer

1.   Locate the PageSettings property for C1PrintDocument in the Properties window and click the ellipsis button.

 

 

The Page Setup dialog box will appear.

 

2.   Locate the Orientation area and select the option for Landscape. Your C1PrintDocument will appear and print in the Landscape orientation.

 

 

3.   Click OK to close the Page Setup dialog box.

In Code

The following code sets the PageSettings property to landscape orientation:

      Visual Basic

Me.C1PrintDocument1.PageSettings.Landscape = True

      C#

this.c1PrintDocument1.PageSettings.Landscape = true;


Send comments about this topic to ComponentOne.
Copyright © 1987-2010 ComponentOne LLC. All rights reserved.