11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

PAUSE<br />

Syntax<br />

PAUSE [wait_time]<br />

Description<br />

The <strong>UniBasic</strong> PAUSE command suspends the UniData process that issues the<br />

command for the amount of time you specify with wait_time, or until a <strong>UniBasic</strong><br />

WAKE command is executed for this process. Keep in mind the following points<br />

when executing PAUSE:<br />

1-565 <strong>UniBasic</strong> <strong>Commands</strong> <strong>Reference</strong><br />

PAUSE has no effect if wait_time is a negative number, or if another<br />

UniData process has previously issued a WAKE command for this process.<br />

To pause a process indefinitely, omit wait_time, or specify a wait_time of 2.<br />

PAUSE must be executed by the process to be paused.<br />

Examples<br />

The following sample program executes the <strong>UniBasic</strong> PAUSE command to pause the<br />

current session:<br />

PAUSE_WAKE<br />

PRINT "How long do you want to pause this session":<br />

INPUT pause_time<br />

PAUSE pause_time<br />

END<br />

The following example executes the preceding program. In this execution, the user<br />

does not enter an amount of time to pause the session, so it is paused indefinitely.<br />

(The cursor rests on the line following the prompt.)<br />

:RUN BP PAUSE_WAKE<br />

How long do you want to pause this session?

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!