Click@Mikechat: that code you posted won't do anything, because you are passing $1- which already has multiple consecutive spaces stripped. $rawmsg on the other hand doesn't have this issue. I don't want to be rude, but I think you were drunk when you made that lol, you're looping from 1 till $len(%text) yet using the increment variable to get tokens, as well as taking the %i'th space delimited token and replacing $chr(32) with $chr(160), but a space delimited token is never a space, so there is actually never any replacement. Also, you are just resetting that %newtext variable each time, so basically that would contain the last token when all looping is done, however since you loop too much ($len instead of $0) it is actually empty when the looping is done.