Cicode Programming Reference > Cicode Function Categories > Page Functions Introduction > PageLast

PageLast

Displays the graphics page that was last displayed. With this function, you can successively recall the last ten pages that were displayed.

Graphics pages displayed using this command cannot be subsequently recalled.

You cannot call this function from the Exit command field (see Page Properties) or a Cicode Object.

Note: This function is not supported in the server process in a multiprocessor environment. Calling this function from the server process results in a hardware alarm being raised.

Syntax

PageLast()

Return Value

0 (zero) if the page is successfully displayed, otherwise an error is returned.

Related Functions

PagePeekLast, PagePopLast, PagePushLast

Example

Buttons

Text

Last Page

Command

PageLast()

Comment

Display the graphics page that was last displayed

PageDisplay("MIMIC1");
! Displays page "MIMIC1".
PageDisplay("MIMIC2");
/* Displays page "MIMIC2" and places page "MIMIC1" onto the PageLast stack. */
PageDisplay("10");
! Displays page "10" and places page "MIMIC2" onto the PageLast stack.
PageLast();
/* Displays the last page on the stack, that is page "MIMIC2" and removes it from the stack. */
PageLast();
/* Displays the last page on the stack, that is page "MIMIC1" and removes it from the stack. */
PageLast();
/* Returns an "Out of range" error code as there are no more pages on the stack.*/

See Also

Page Functions