<< Click to Display Table of Contents >> Navigation: ThinBASIC Modules > Tokenizer > Tokenizer_GetNextToken |
Description
Returns the next token from a string buffer.
Syntax
pKey = Tokenizer_GetNextToken(Buffer, CurrentPosition, TokenMainType, Token [, TokenSubType])
Returns
Number.
In case token found is a user key, returned number is a pointer to user key.
Parameters
Name |
Type |
Optional |
Meaning |
Buffer |
String variable |
No |
Buffer containing the string to be tokenized. |
CurrentPosition |
Numeric variable |
No |
Current Tokenizer position. Parameter passed BYREF so a variable is needed and not a numeric expression. |
TokenMainType |
Numeric variable |
No |
Token main type. See Tokenizer equates for main type reference. Parameter passed BYREF so a variable is needed and not a numeric expression. |
TokenVariable |
String variable |
No |
Parameter passed BYREF so a variable is needed and not a string expression. |
TokenSubType |
Numeric variable |
Yes |
Token sub type. This information is relevant only for user defined keys. See Tokenizer_KeyAdd function. Parameter passed BYREF so a variable is needed and not a numeric expression. |
Remarks
Important: all parameters passed to this function must be variable and not expressions.
They must be variable because passed by reference in order to get back information.
Restrictions
See also
Examples