![]() |
![]() |
![]() |
![]() |
Keywords can be subdivided into functions, which return a value, and commands, which do not. In practice you use functions and commands together, often using functions as if they were commands, ignoring the values they return.
This chapter lists all the keywords, grouped according to their purpose. Use this chapter if you know what youd like to do, but not which function or command will do it.
The chapter which follows this one lists the keywords alphabetically, with explanations and full specifications.
Section Contents
Repeat a set of instructions |
DO...UNTIL, WHILE...ENDW |
Do either one set of instructions or another set, or another, or another... |
IF...ENDIF |
Go... |
|
...to a specified label |
GOTO |
...to one of a list of labels |
VECTOR85ENDV |
...to the end/start of a repeating set of instructions |
BREAK, CONTINUE |
...back to the calling procedure |
RETURN |
End the program |
STOP |
Raise an error |
RAISE |
Put an explanatory comment in your program |
REM |
Declare an error-handler |
ONERR...ONERR OFF |
Let the program continue after an error |
TRAP |
After an error, find out what the error was |
ERR, ERR$ |
|
ERRX$ |
Display a string to be edited and get a value from the keyboard |
EDIT |
Get a value from the keyboard |
INPUT |
Display text, numbers etc. |
|
Set screen update method |
gUPDATE |
Pause... |
|
...for a number of seconds |
PAUSE |
...until a key is pressed |
GET, GET$ |
Position or hide the cursor |
AT, CURSOR |
Clear the text window |
CLS |
Sound the buzzer |
BEEP |
Set the size/position of the text window |
SCREEN |
Get information on the text window |
SCREENINFO |
Set text window font and style |
FONT, STYLE |
Find out which key was pressed, if any |
KEY, KEY$, GET, GET$ |
Find out what combination of modifiers was pressed |
KMOD |
Disable/enable stopping from a running program |
ESCAPE OFF/ON |
Turn the Psion off |
OFF |
Section Contents
Copy a file |
COPY |
Delete or rename a file |
DELETE, RENAME |
Check to see if a certain file exists |
EXIST |
Find out what files there are |
DIR$ |
|
CACHE |
Load an OPL module file so you can use the procedures in it |
LOADM |
Remove a module from memory |
UNLOADM |
|
INCLUDE |
|
DECLARE EXTERNAL |
|
EXTERNAL |
Create a new data file, databse or table |
CREATE |
OPEN or CLOSE a data file, database or table |
OPEN, OPENR, CLOSE |
|
DELETE |
Use a different data file that has been opened |
USE |
|
COMPRESS |
Once a data file has been OPENed, you can: |
|
Make a new record |
APPEND |
Change a record |
UPDATE |
Search for those records which contain a certain string |
FIND, FINDFIELD |
Erase a record |
ERASE |
Move to a different record |
FIRST, LAST, NEXT, BACK, POSITION |
Count the records |
COUNT |
Find whether youre at the end of the file yet |
EOF |
Find the current record number |
POS |
|
RECSIZE |
|
BEGINTRANS |
|
COMMITTRANS |
|
INTRANS |
|
ROLLBACK |
|
BOOKMARK |
|
GOTOMARK |
|
KILLMARK |
|
INSERT |
|
MODIFY |
|
PUT |
|
CANCEL |
|
COMPACT |
Create directory |
MKDIR |
Set current directory |
SETPATH |
Remove directory |
RMDIR |
Declare variables |
GLOBAL, LOCAL |
|
CONST |
Find how much free memory there is on a device |
SPACE |
Specify a device or file to print to |
LOPEN |
Close the print device or file opened with LOPEN |
LCLOSE |
Print to a device or file |
LPRINT |
Section Contents
Trig functions |
COS, SIN, TAN, ACOS, ASIN, ATAN |
Convert between degrees and radians |
RAD, DEG |
Raise e to a power |
EXP |
Logarithms |
LN, LOG |
Pi as a constant |
PI |
Square root |
SQR |
Use random numbers |
RND, RANDOMIZE |
Unsigned integer/pointer arithmetic (in the 64K limit) |
UADD, USUB |
Find the greatest or smallest value in the list |
MAX, MIN |
Average the list |
MEAN |
Add up the list |
SUM |
Find the standard deviation or variance |
STD, VAR |
Knock the minus sign off a number |
ABS, IABS |
Take whole number, removing any fractional part |
INT, INTF |
Convert... |
|
...an integer into floating-point |
FLT |
...an integer into a hexadecimal string |
HEX$ |
...a number into a string |
FIX$, GEN$ SCI$, NUM$ |
...a string into a number |
EVAL, VAL |
Copy characters from a string |
LEFT$, MID$, RIGHT$ |
Repeat a string |
REPT$ |
Make a string upper or lower case |
UPPER$, LOWER$ |
Find out... |
|
...how long a string is |
LEN |
...the character code of the first character of a string |
ASC |
...where a certain string is within a string |
LOC |
Convert... |
|
... a string of digits to a number |
VAL |
...a number to a string |
FIX$, GEN$ SCI$, NUM$ |
Get the character with a certain character code |
CHR$ |
Find out the current date and time... |
|
...as a string |
DATIM$ |
...just the current time |
SECOND, MINUTE, HOUR |
...just the current date |
DAY, MONTH, YEAR |
Find out... |
|
...the number of days between two dates |
DAYS |
...what day of the week, or what week number, a certain date falls in |
DOW, WEEK |
Express... |
|
...1-12 as the name of a month |
MONTH$ |
...1-7 as a day of the week |
DAYNAME$ |
Convert between seconds and dates |
DATETOSECS, SECSTODATE |
|
DAYSTODATE |
Section Contents
Set current position |
gAT, gMOVE |
|
gSETPENWIDTH |
Draw a line |
gLINEBY, gLINETO |
Draw a sequence of lines |
gPOLY |
|
gCIRCLE |
|
gELLIPSE |
Draw a rectangle |
gBOX |
Draw a border |
gBORDER, gXBORDER |
Fill a rectangle |
gFILL |
Invert a rectangle |
gINVERT |
Scroll a rectangle |
gSCROLL |
Get current position |
gX, gY |
Display a running clock |
gCLOCK |
Draw a 3-D button (key) |
gBUTTON |
|
gDRAWOBJECT |
Display a list of expressions |
gPRINT |
Display text in a cleared box |
gPRINTB |
Display text neatly clipped |
gPRINTCLIP |
Find width required by text |
gTWIDTH |
Display text underlined/highlighted |
gXPRINT |
Set graphics to set / clear / invert pixels |
gGMODE |
Set text to set / clear / invert / replace pixels |
gTMODE |
Set font to use |
gFONT |
Load and unload user-defined fonts |
gLOADFONT, gUNLOADFONT |
Set text to bold / underline / inverse / double / mono / italic |
gSTYLE |
Create a new window |
gCREATE |
Set position and/or size of a window |
gSETWIN |
Set order to show windows |
gORDER |
Get order of a window |
gRANK |
Set window visible / invisible |
gVISIBLE |
Get screen position of a window |
gORIGINX, gORIGINY |
Create a bitmap |
gCREATEBIT |
Load a bitmap from file |
gLOADBIT |
Clear a window / bitmap |
gCLS |
Save window / bitmap to bitmap file |
gSAVEBIT |
Close down a window / bitmap |
gCLOSE |
Set which window / bitmap to use |
gUSE |
|
gCOLOR |
|
gGREY |
|
gGREY |
|
DEFAULTWIN |
|
DEFAULTWIN |
Fill an area with repetitions of another window / bitmap |
gPATT |
Copy an area from one window / bitmap to another |
gCOPY |
Read data back from a window / bitmap |
gPEEKLINE |
Get ID number of a window / bitmap |
gIDENTITY |
Get size of a window / bitmap |
gWIDTH, gHEIGHT |
|
gINFO |
|
gINFO32 |
Create a sprite |
CREATESPRITE |
Define bitmap-sets for a sprite |
APPENDSPRITE, CHANGESPRITE |
Draw a sprite |
DRAWSPRITE |
Set a sprites position |
POSSPRITE |
Close a sprite |
CLOSESPRITE |
Start a new set of menus |
mINIT |
Define a menu |
mCARD |
|
mCASC |
Display menus |
MENU |
|
mPOPUP |
Start a new dialog |
dINIT |
Position a dialog |
dPOSITION |
Define text for a dialog |
dTEXT |
Define an edit box for a dialog |
dEDIT |
|
dEDITMULTI |
Define a secret edit box for a dialog |
dXINPUT |
Define a filename edit box for a dialog |
dFILE |
Define a choice list for a dialog |
dCHOICE |
|
dCHECKBOX |
Define a numeric edit box for a dialog |
dFLOAT, dLONG |
Define a date or time edit box for a dialog |
dDATE, dTIME |
Define exit keys for a dialog |
dBUTTONS |
Display a dialog |
DIALOG |
Display a simple alert dialog |
ALERT |
Display/hide status window |
STATUSWIN |
Get status window information |
STATWININFO |
Set a programs name |
SETNAME |
Initialise a |
DIAMINIT |
Position |
DIAMPOS |
Display information messages |
GIPRINT |
Display busy messages |
BUSY |
Define an OPA |
APP...ENDA |
Declares an OPAs icon |
ICON |
|
CAPTION |
|
FLAGS |
|
TYPE |
|
EXT |
|
PATH |
Mark an OPA as locked or unlocked |
LOCK |
|
USR, USR$ |
Find out where a certain variable is in memory |
ADDR |
Store a value in a specific place in memory |
POKE commands |
Find out the value stored at a certain place in memory |
PEEK commands |
Open any type of file |
IOOPEN |
Read from a file opened with IOOPEN |
IOREAD |
Write to a file opened with IOOPEN |
IOWRITE |
Close a file opened with IOOPEN |
IOCLOSE |
Position within a file opened with IOOPEN |
IOSEEK |
Keywords which provide low-level access to the Psion |
|
|
CALL, OS |
Perform an asynchronous I/O function |
IOA, IOC |
Cancel an asynchronous I/O function |
IOCANCEL |
Wait for completion of a function performed by IOA or IOC |
IOWAIT, IOWAITSTAT, |
|
IOWAITSTAT32 |
Signal completion of an I/O function |
IOSIGNAL |
Ensure an asynchronous handler runs |
IOYIELD |
Perform a synchronous I/O function |
IOW |
Perform an asynchronous keyboard read |
KEYA |
Cancel a KEYA |
KEYC |
Get command line information |
CMD$, GETCMD$ |
|
SETDOC |
|
GETDOC$ |
Parse a full file specification |
PARSE$ |
Check for system events |
GETEVENT, TESTEVENT |
|
GETEVENT32, GETEVENT32A |
|
GETEVENTC |
|
POINTERFILTER |
|
ODBINFO |
|
LOADLIB, LINKLIB |
|
UNLOADLIB |
|
FINDLIB, GETLIBH |
|
NEWOBJ, NEWOBJH |
|
SEND, ENTERSEND, ENTERSEND0 |
Allocate a heap cell |
ALLOC |
Free an allocated cell |
FREEALLOC |
Change size of allocated cell |
REALLOC |
Insert or delete section of cell |
ADJUSTALLOC |
Find length of allocated cell |
LENALLOC |
|
CACHETIDY |
|
CACHEHDR |
|
CACHEREC |
|
SETFLAGS |
|
CLEARFLAGS |
![]() |
![]() |
![]() |
![]() |