beautypg.com

Rockwell Automation 2708-NBD VBASIC Language Development Kit User Manual

Page 74

background image

Appendix C

Application Library Subroutines

C–6

Note: In EnvPC, dashes are returned, not slashes (MM-DD-YYYY).

CL1

Clears the top line of the display and homes cursor.

CL2

Clears line 2 and left justifies cursor.

SUB CL1
SUB CL2

PC1

Prints a string centered on line 1.

PC2

Prints a string centered on line 2.

PC1 s$
SUB PC1 ( s$ )
SUB PC2 ( s$ )

ReadFlush

Flushes the keyboard buffer.

This clears the keyboard buffer of any pending keystrokes.

ReadFlush
SUB ReadFlush

ReadStrField%

Input a string on the display

The string$ contents are placed on the screen and may be edited by the user.
This default may be inhibited using NODEFAULT.

The attr% is made by adding the following:

AUTOEXIT

Causes the field to be auto exited

. . . . .

BLANKPAD

Selects blank padding instead of underscores

. . . . .

SECURE

The field is displayed as asterisks

. . . . . . . .

NOEDIT

Displayed but cannot be edited

. . . . . . . .

NOCLEAR

Inhibits auto clear on input

. . . . . .

NOCURSOR

Inhibits display of cursor during edit

. . . .

FORMEXIT

Allow arrows to exit the field entry

. . . . .

NODEFAULT

Do not use the default value in the string

. . . .

USETABLE

Use CHARTABLE$ to restrict legal characters

. . . . .

The fieldlength% is in characters. The startingchar% specifies the offset from
the beginning of the field at which editing is to start, this begins at 0. Note
that the global EXITOFFSET% is set to the cursor position at exit. These
may be used to restart a read which was interrupted by some event.