LoginLogin
Might make SBS readonly: thread

MID$

Root / Documentation / [.]

Created:
Copy a substring out of a string.

Syntax

MID$ string$, startIndex% {, length% } OUT substring$
InputDescription
string$The string to copy from.
startIndex%The index in string$ to start copying from.
length%The number of characters to copy (optional.) If omitted, copy characters up to the end of string$.
OutputDescription
substring$The substring copied from string$.

Examples

'copy the word "brown"
PRINT MID$("The quick brown fox",10,5)
'copy the alphabet starting at N
PRINT MID$("ABCDEFGHIJKLMNOPQRSTUVWXYZ",13)

No posts yet (will you be the first?)