Roulette Xtreme 2.0 - System Designer
Last Answer (Condition)
Identifier Index > L > Last Answer (Condition)

Glossary Item Box

Last Answer

Format:  initial-condition-statement  Last Answer  ( Yes | No)

where

  • initial-condition-statement = any valid condition statement that use these identifiers listed below

  • Yes | No = either a Yes or No required constant identifier.

Description

The Last Answer is a supporting condition identifier that references the internal variable answer which gets assigned by the Ask action statement.   When using the Last Answer identifier in a condition statement, the answer value is compared against either the constant identifier Yes or No to produce a logical true or false result.  When the outcome of the condition is evaluated as true the program control is passed to the body of the condition block.

Example

When we reached the end of our session, we are presenting to the user the opportunity to play another session.  The results from the dialog box will be stored in the internal variable answer.  We will then use the Last Answer identifier with a condition statement to determine if the user wants to quit and stop the session.  The following example will perform this task.  

RX Script Copy Code
Ask "Do want to play another session?"

if the Last Answer is No then
begin
  Stop Session
end

Copyright © 2003 UX Software. All rights reserved