# Variables

1) User variables

Defined by user. The type of a variable is determined when a value (integer or string) is assigned to it for the first time. Once the type of the variable is determined, values of a different type cannot be assigned to it.

2) System variables

Each system variable has a predefined type and value. Used with particular commands.

Variables | Type | Initial value | Related commands
--- | --- | --- | ---
groupmatchstr1 ... groupmatchstr9 | string | "" | waitregex, strjoin, strsplit, strmatch
inputstr | string | "" | recvln, waitln, waitn, waitrecv, waitregex, sprintf, passwordbox, filenamebox, inputbox
matchstr | string | "" | waitregex, strmatch
param1, param2 ... param9, paramcnt | string, interger | *1 | *1
result | integer | 0 | bplusrecv, bplussend, connect, cygconnect, kmtfinish, kmtget, kmtrecv, kmtsend, logopen, quickvanrecv, quickvansend, recvln, testlink, wait, waitevent, waitln, waitn, waitrecv, waitregex, xmodemrecv, xmodemsend, zmodemrecv, zmodemsend, sprintf, str2int, strcompare, strlen, strmatch, strscan, fileconcat, filecopy, filecreate, filedelete, fileread, filereadln, filerename, filesearch, filestrseek, filestrseek2, findfirst, findnext, clipb2var, crc32file, getdate, gettime, getver, ifdefined, var2clipb, yesnobox, getfileattr, setfileattr, foldercreate, folderdelete, foldersearch
timeout | integer | 0 | recvln, wait, wait4all, waitevent, waitn, waitln, waitrecv, waitregex
mtimeout *2 | integer | 0 | recvln, wait, waitevent, waitn, waitln, waitrecv, waitregex

*1 The second to ninth command line parameter of MACRO. The first parameter (param1) is the macro file name. "paramcnt" is a number of parameter counter including the fisrt parameter. See "Command line".
*2 Precision is about 50 msec.