You can use the following primitives to manipulate strings (in the argument field of GASP statements).
.LEN("str")
Calculate the
length of string, "str",
as an absolute expression. For example, .RES.B
.LEN(“sample”)
reserves six bytes of memory.
.INSTR("string",
"seg", ix)
Search for the
first occurrence of seg
after position ix
of string.
For example, .INSTR("ABCDEFG",
“CDE”,
0) evaluates to
the absolute result 2.
The result is -1
if seg
does not occur in string
after position ix.
.SUBSTR("string", start,
len)
The substring
of string
beginning at byte number start
and extending for len
bytes.