Creates and launches a page that you specify. You can use CLEAR Function to remove the page.

Page.RUN

Parameters

Page

Type: Page

After you define this variable, you can run the following page functions:

  • SETTABLEVIEW
  • SETRECORD
  • GETRECORD
  • RUN
  • RUNMODAL.
The variable is automatically cleared after this function is executed.

If the page you specify does not exist, you receive a compile error.

Remarks

If, at design time, you know the specific page that you want to run, then you can create a Page variable, set the Subtype of the variable to a specific page, and then use this function or the RUNMODAL Function (Page) on the Page variable.

If you do not know the page that you want to run, then use the PAGE.RUN Function or the PAGE.RUNMODAL Function and specify the page in the Number parameter.

After you define the page variable, you can use it before you run the page. If you use the RUNMODAL Function (Page), you can use the variable before and after you run the page.

Example

This example shows how to use the RUN function. Assume the variable MyPage has been defined as Page 1.

 Copy Code
MyPage.XXX; // any user-defined function
MyPage.SETTABLEVIEW(MyRecord);
MyPage.SETRECORD(MyRecord);
MyPage.RUN;

See Also