getting the first so many chars of a string?
adri
Posts: 34
hi
I want to grab the first 'x' number of chars from a string to do a string compare later.
If anyone can help it'd be appreciated..
Cheers
Adri
I want to grab the first 'x' number of chars from a string to do a string compare later.
If anyone can help it'd be appreciated..
Cheers
Adri
Comments
var
byte mystring[noparse][[/noparse] 32 ]
pub
bytemove(@mystring,string("Roger Williams"),15)
mystring[noparse][[/noparse] 5 ] := 0
text.out(@mystring) 'prints "Roger"
Post Edited (localroger) : 8/16/2009 1:09:45 PM GMT