On 5/19/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Hi all,
Is there a RunRev TRIM command? To remove beginning and/or trailing spaces.
If there is, I can't find it.
If there isn't, how would I script the function for this?
There was a lot of discussion about this a few months ago, so an
archive search might prove useful. However here are a couple of
suggestions to get you going:
If the extra white spaces are only at the beginning & end of the text
i.e. not between words, then this one-liner will do:
put word 1 to -1 of myText into myText
If there could be extra spaces between words, then this is what I use:
put empty into myTrimmedText
repeat for each word w in myText
put w & space after myTrimmedText
end repeat
delete last char of myTrimmedText -- get rid of last space
HTH,
Sarah
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution