This documentation is archived and is not being maintained.
strLine Function
Retrieves a single line from a string that spans multiple lines by using the newline character (\n).
str strLine(str string, int count)
|
Parameter
|
Description
|
|
string
|
The string to be extracted.
|
|
count
|
The number of the line to extract.
The first line is represented by 0.
|
A single line from a string.
static void strLineExample(Args _arg)
{
str mytxt = "first-line\nsecond-line\nlast-line";
;
// Prints "second-line".
print strLine(mytxt,1);
// Prints "last-line".
print strLine(mytxt,2);
pause;
}