mIRC Homepage
Posted By: Zelda4ever32 $1() - 27/04/04 10:52 PM
Hey Everyone,

Would it be possible to make $1(), $2(), $3(), etc. like this?:
$2($read(Sampletxt.txt,3))
It would return the second word of line 3 in sample.txt.
And the $1( .. )- etc would still work too.

Thanks,
-Zelda4ever
aka "The Big 'Z'"
Posted By: Hrung Re: $1() - 27/04/04 11:07 PM
Try $gettok. For example:

$gettok($read(Sampletxt.txt,3),N,32)

returns the Nth word. You can also use a range for N (example, 1-4 or even just 1-) just as you can with $1-. As for the meaning of the 32, it is the ascii value of space, which is the character that seperates the tokens in this case.

Alternatively, you can /tokenize 32 <line of text> to fill the $1- with your text
© mIRC Discussion Forums