var$ = MidStr(string$, startpos[, len, encoding])
len
characters from string$
(starting at position startpos
)
as a new string. The starting position startpos
needs to be specified
in characters, not in bytes.
Starting with Hollywood 6.1 len
may be omitted or set to -1. In that case,
the remaining characters in string$
will be returned.
The optional encoding
parameter can be used to set the character encoding
to use. This defaults to the default string encoding set using SetDefaultEncoding().
See Character encodings for details.
test$ = MidStr("Hello World!", 4, 3) Print(test$)This will print "o W" to the screen.