CurrentPage

<< Click to Display Table of Contents >>

Navigation:  Layout Functions >

CurrentPage

Previous pageReturn to chapter overviewNext page

Moves to the current active page, or returns the number of the current active page. This is the page where you can insert objects, all further output-calls will insert objects onto this page. It is independently from the Visual Page shown in the preview. (see "Multipage Documents" in the Programmer's Manual)

You can move at any time to any page to insert objects.

property long VPE.CurrentPage

read / write; runtime only

Possible Values:

The number of the current active page.

Remarks:

In case of an error, LastError is set.

 

If you want to show the preview and let the user work with it (e.g. scroll and print), while your application is still generating the document, see "Generating a Document while the Preview is open" in the Programmer's Manual for details.

Examples:

Doc.CurrentPage = 5    // moves to page 5

n = Doc.CurrentPage    // returns the value 5

 

Doc.CurrentPage = 5    // moves to page 5

Doc.Print(1, 1, "This is page 5")

Doc.CurrentPage = 2    // moves to page 2

Doc.Print(1, 1, "This is page 2")