QMBasic Statements and Functions by Name

Top  Previous  Next

 

@(x,y)Terminal cursor movement and control
ABORTAbort to command prompt
ABORTEAbort to command prompt with Pick style message handling
ABORTMAbort to command prompt with Information style message handling
ABS()Absolute value
ABSS()Multi-valued absolute value
ACCEPT.SOCKET.CONNECTION()Accept an incoming connection on a server socket
ACOS()Arc-cosine
ALPHA()Test if string holds only alphabetic characters
ANDS()Multi-valued logical AND
ARG()Returns an argument variable based on its argument list position
ARG.COUNT()Returns the number of arguments passed into a subroutine
ASCII()Convert an EBCDIC string to ASCII
ASIN()Arc-sine
ASSIGNED()Test whether variable is assigned
ATAN()Arc-tangent
BEGIN TRANSACTIONStart a new transaction
BINDKEY()Set, remove, query, save or restore key bindings
BITAND()Bitwise logical AND operation
BITNOT()Bitwise logical NOT operation
BITOR()Bitwise logical OR operation
BITRESET()Turn off specified bit
BITSET()Turn on specified bit
BITTEST()Test specified bit
BITXOR()Bitwise logical exclusive OR operation
BREAKEnable or disable break key handling
CALLCall an external subroutine
CASEPerform statements according to multiple conditions
CATALOGUED()Check catalogue entry
CATS()Concatenate elements of a dynamic array
CHAINTerminate program and execute a command
CHANGE()Replace substring in a string
CHAR()Get ASCII character for a given collating sequence value
CLASSDeclare a class module
CLEARSet all local variables to zero
CLEARCOMMONSet all unnamed common variables to zero
CLEARDATAClear DATA queue
CLEARFILEClear a file, deleting all records and releasing disk space
CLEARINPUTClear keyboard type-ahead
CLEARSELECTClear one or all select lists
CLOSEClose a file
CLOSESEQClose a record opened for sequential access
CLOSE.SOCKETClose a socket
COL1()Start of substring position from FIELD()
COL2()End of substring position from FIELD()
COMMITCommit transaction updates
COMMONDefine a common block
COMPARE()Compare strings
CONFIG()Returns the value of a configuration parameter
CONNECT.PORT()Connect a serial port to a phantom process
CONTINUEContinue next iteration of a loop
CONVERTSubstitute characters with replacements
CONVERT()Substitute characters with replacements
COS()Cosine
COUNT()Count occurrences of substring in string
COUNTS()Multi-valued variant of COUNT()
CREATECreate an empty sequential file record
CREATE.FILECreate a file
CREATE.SERVER.SOCKET()Open a server socket
CROP()Remove redundant mark characters
CRTSynonym for DISPLAY
CSVDQ()Dequote a CSV string
DATASave text in DATA queue
DATE()Return the current date as a day number
DCOUNT()Count delimited substrings in string
DEBUGEnter debugger
DECRYPT()Decrypt text
DEFFUNDefine a function
DELDelete a field, value or subvalue
DELETEDelete record from a file
DELETE()Delete a field, value or subvalue
DELETELISTDelete a saved select list
DELETESEQDelete an operating system file
DELETEUDelete record from a file preserving locks
DIMSynonym for DIMENSION
DIMENSIONSet matrix dimensions
DISINHERITDisinherit an object
DISPLAYOutput to the display
DIR()Return the contents of a directory
DIV()Divide
DOWNCASE()Convert string to lowercase
DPARSESplit elements of a delimited string
DPARSE.CSVSplit elements of a CSV format delimited string
DQUOTE()Synonym for QUOTE()
DTX()Convert a number to hexadecimal
EBCDIC()Convert an EBCDIC string to ASCII
ECHOEnable or disable input echo
ENCRYPT()Encrypt data
ENDTerminate program or statement group
END TRANSACTIONTerminate a transaction
ENTERSynonym for CALL
ENV()Retrieve an operating system environment variable
EQS()Multi-valued equality test
EQUATEDefine a symbolic name for a constant or matrix element
ERRMSGDisplay a Pick style message from the ERRMSG file
EXECUTEExecute a command
EXITLeave a loop
EXP()Exponential
EXTRACT()Extract a field, value or subvalue
FIELD()Extract delimited fields
FIELDS()Multi-valued variant of FIELD()
FIELDSTORE()Replace or insert delimited fields
FILEOpen a file and access data by field name
FILEINFO()Return information about an open file
FILELOCKLock a file
FILEUNLOCKUnlock a file
FINDFind a string in a dynamic array element
FINDSTRFind a substring in a dynamic array element
FLUSHFlush sequential file data to disk
FMT()Format a string
FMTS()Format a dynamic array
FOLD()Break a string into sections, splitting at spaces where possible
FOLDS()Multi-valued variant of FOLD()
FOOTINGSet footing text
FOR / NEXTIterative loop construct
FORMLISTCreate a select list from a dynamic array
FUNCTIONDeclare function name and arguments
GES()Multi-valued greater than or equal to test
GETLISTRestore a saved select list
GET.MESSAGES()Retrieve messages from the message queue
GET.PORT.PARAMS()Get serial port parameters
GETNLS()Get national language support parameter value
GETPUGet a characteristic of a print unit
GETREM()Get remove pointer position
GO / GOTOJump to a label
GOSUBEnter an internal subroutine
GTS()Multi-valued greater than test
HEADINGSet heading text
HUSHSuppress or enable display output
ICONV()Perform input conversion
ICONVS()Perform input conversion on a dynamic array
IDIV()Integer division
IF / THEN / ELSEPerform conditional statements
IFS()Multi-valued conditional expression
INDEX()Locate occurrence of substring within a string
INDEXS()Multi-valued equivalent of INDEX()
INDICES()Return information about alternate key indices
INHERITInherit an object
INMAT()Return status of matrix operations
INPUTInput a string from the keyboard or data queue
INPUT @Input a string from the keyboard or data queue
INPUTCLEARSynonym for CLEARINPUT
INPUTCSVInput CSV format data
INPUTERRSynonym for PRINTERR
INPUTFIELDInput a string with function key handling
INSInsert a field, value or subvalue
INSERT()Insert a field, value or subvalue
INT()Truncate value to integer
ITYPE()Execute a compiled I-type
KEYCODE()Input a single keystroke from the keyboard with terminfo translation
KEYEDITDefine editing keys for INPUT @
KEYEXITDefine exit keys for INPUT @
KEYIN()Input a single keystroke from the keyboard
KEYINC()Input a single keystroke from the keyboard with case inversion
KEYINR()Input a single keystroke from the keyboard in raw mode (no internal processing)
KEYREADY()Test for keyboard input
KEYTRAPDefine trap keys for INPUT @
LEN()Return length of a string
LENS()Multi-valued equivalent of LEN()
LES()Multi-valued less than test
LISTINDEX()Return position of an item in a delimited list
LN()Natural log
LOCATELocate string in dynamic array
LOCATE()Locate string in dynamic array
LOCKSet task lock
LOGMSGAdd an entry to the system error log
LOOP / REPEATDefine a loop to be repeated
LOWER()Convert delimiters to lower level
LOCALDeclares an internal subroutine or function that has private local variables
LTS()Multi-valued less than or equal to test
MARK.MAPPINGControl field mark translation in directory files
MATMatrix initialisation or copy
MATBUILDBuild a dynamic array from matrix elements
MATCHFIELD()Return portion of string matching pattern
MATPARSEBreak a dynamic array into matrix elements
MATREADRead a record, parsing into a matrix
MATREADCSVRead a CSV format text item into a matrix
MATREADLRead a record setting a read lock, parsing into a matrix
MATREADURead a record setting an update lock, parsing into a matrix
MATWRITEWrite a record from matrix elements
MATWRITEUWrite a record from matrix elements, retaining any lock
MAX()Returns the greater of two values
MAXIMUM()Find the greatest value in a dynamic array
MIN()Returns the lesser of two values
MINIMUM()Find the lowest value in a dynamic array
MOD()Modulus value from division
MODS()Multi-valued modulus value from division
NAPSuspend program for a short period
NEG()Arithmetic inverse
NEGS()Multi-valued arithmetic inverse
NES()Multi-valued inequality test
NOBUFTurn off buffering for a record opened using OPENSEQ
NOT()Logical NOT
NOTS()Multi-valued logical NOT
NULLNo operation
NUM()Test if string holds a numeric value
NUMS()Multi-valued variant of NUM()
OBJECT()Instantiates an object
OBJINFO()Returns information about an object variable
OCONV()Perform output conversion
OCONVS()Perform output conversion on a dynamic array
ON GOSUBJump to one of a list of labels selected by value
ON GOTOEnter one of a list of internal subroutines selected by value
OPENOpen a file
OPENPATHOpen a file by pathname
OPENSEQOpen a record for sequential access
OPEN.SOCKET()Open a socket connection
ORS()Multi-valued logical OR
OS.ERROR()Return operating system error information
OS.EXECUTEExecute an operating system command
OUTERJOIN()Fetch data from a file using an "outer join"
PAGEStart a new page
PAUSEPause execution until awoken by another process
PERFORMSynonym for EXECUTE
PRECISIONSet number of decimal places in numeric conversion
PRINTOutput to a logical print unit
PRINTER CLOSEClose a print unit
PRINTER DISPLAYAssociate a print unit with the display
PRINTER FILEAssociate a file with a print unit
PRINTER NAMEAssociate a print device with a print unit
PRINTER OFFDisable print unit zero
PRINTER ONEnable print unit zero
PRINTER RESETReset default print unit and display
PRINTER SETTINGSet a print unit parameter
PRINTER.SETTING()Set or retrieve a print unit parameter
PRINTERRDisplay an error message
PRIVATEDeclare private variables in a local subroutine or a class modules
PROCREADRead data from the PROC primary input buffer
PROCWRITEWrite data to the PROC primary input buffer
PROGRAMDeclare program name
PROMPTSet the input prompt character
PUBLICDeclare public properties in a class module
PWR()Raise value to power
QUOTE()Enclose a string in quotes
RAISE()Convert delimiters to higher level
RDIV()Rounded integer division
READRead a record from a file
READBLKRead bytes from a sequential file
READCSVRead a CSV format text item
READLRead a record from a file, setting a read lock
READLISTSave a select list in a dynamic array
READNEXTRead a record id from a select list
READSEQRead from a sequential file
READURead a record from a file, setting an update lock
READVRead a field from a record in a file
READVLRead a field from a record in a file, setting a read lock
READVURead a field from a record in a file, setting an update lock
READ.SOCKET()Read data from a socket
RECORDLOCKED()Test if record is locked
RECORDLOCKLSet a read lock on a record
RECORDLOCKUSet an update lock on a record
RELEASERelease record or file locks
REM()Remainder value from division
REMARKAlternative syntax for comments
REMOVERemove an item from a dynamic array
REMOVE()Remove an item from a dynamic array
REPLACE()Replace a field, value or subvalue
RESTORE.SCREENRestore screen image data
RETURNReturn from program or subroutine
RETURN TOReturn from program or subroutine to a specific label
REUSE()Reuse element of numeric arrays in mathematical functions
RND()Generate random number
ROLLBACKDiscard transaction updates
RQMSynonym for SLEEP
RTRANS()Fetch data from a file
SAVE.SCREEN()Save screen image data
SAVELISTSave a select list in the $SAVEDLISTS file
SEEKPosition a sequential file
SELECTBuild a select list of all records in an open file
SELECTETransfer select list 0 to a select list variable
SELECTINDEXBuild a select list from an alternate key index
SELECTINFO()Return information regarding a select list
SELECTLEFTScan left through an alternate key index
SELECTNBuild a numbered select list of all records in an open file
SELECTRIGHTScan right through an alternate key index
SELECTVBuild a select list variable of all records in an open file
SENTENCE()Returns the command line that started the current program
SEQ()Get collating sequence value for a given ASCII character
SERVER.ADDR()Find the IP address for a given server name
SET.ARGSets an argument variable based on its argument list position
SET.EXIT.STATUSSet final exit status value
SET.PORT.PARAMS()Set serial port parameters
SET.SOCKET.MODE()Set mode of a socket
SETLEFTSet alternate key index scan position to leftmost
SETNLS()Set national language support parameter value
SETPUSet a characteristic of a print unit
SETRIGHTSet alternate key index scan position to rightmost
SETREMSet remove pointer position
SHIFT()Perform bit shift
SIN()Sine                
SLEEPSuspend program to / for given time
SOCKET.INFO()Retrieve information about a socket
SOUNDEX()Form a soundex code value for a string
SOUNDEXS()Multi-valued variant of SOUNDEX()
SPACE()Create a string of spaces
SPACES()Multi-valued variant of SPACE()
SPLICE()Concatenates elements of two dynamic arrays, inserting a string between the items.
SQRT()Square root
SQUOTE()Enclose a string in single quotes
SSELECTBuild a sorted select list of all records in an open file
STATUS()Return status from previous operation
STATUSReturns a dynamic array of information about an open file
STOPTerminate program
STOPETerminate program with Pick style message handling
STOPMTerminate program with Information style message handling
STR()Create a string from a repeated substring
STRS()Multi-valued variant of STR()
SUBR()Call a subroutine as a function
SUBROUTINEDeclare subroutine name and arguments
SUBSTITUTE()Multi-valued substring replacement
SUBSTRINGS()Multi-valued substring extraction
SUM()Sum lowest level elements of a numeric array
SUMMATION()Sum all elements of a numeric array
SWAP()Synonym for CHANGE()
SWAPCASE()Invert case of alphabetic characters in a string
SYSTEM()Return system information
TAN()Tangent
TCLREADReturns the sentence that started the current program
TERMINFO()Retrieve information from the terminfo database
TIME()Return the current time
TIMEDATE()Return the date and time as a string
TIMEOUTSets a timeout for READBLK and READSEQ
TRANS()Fetch data from a file
TRANSACTION ABORTAbort a transaction
TRANSACTION COMMITCommit a transaction
TRANSACTION STARTStart a new transaction
TRIM()Trim characters from string
TRIMB()Trim spaces from back of string
TRIMBS()Multi-valued variant of TRIMB()
TRIMF()Trim spaces from front of string
TRIMFS()Multi-valued variant of TRIMF()
TRIMS()Multi-valued variant of TRIM()
TTYGET()Get current terminal mode settings
TTYSETSet terminal modes
UNASSIGNED()Test whether variable is unassigned
UNLOCKRelease task lock
UNTILLeave loop if condition is met
UPCASE()Convert string to uppercase
VSLICE()Extract a value slice from a dynamic array
WAKERestart execution of a process on a PAUSE
WEOFSEQWrite end of file position to sequential file
WHILELeave loop unless condition is met
WRITEWrite a record to a file
WRITEBLKWrite bytes to a sequential file
WRITECSVWrite CSV format data to a sequential file
WRITESEQWrite to sequential file
WRITESEQFWrite to sequential file, flushing to disk
WRITEUWrite a record to a file, retaining any lock
WRITEVWrite a field to a record in a file
WRITEVUWrite a field to a record in a file, retaining any lock
WRITE.SOCKET()Write data to a socket
VOIDDiscard the result of evaluating an expression
XLATE()Synonym for TRANS()
XTD()Convert a hexadecimal number