home *** CD-ROM | disk | FTP | other *** search
- on rmvBlanks strng
- if stringp(strng) = 0 then
- return -1
- end if
- set lng to the number of chars in strng
- repeat with i = 1 to lng
- if char i of strng = " " then
- nothing()
- next repeat
- end if
- exit repeat
- end repeat
- set start to i
- repeat with i = 1 to lng
- if (char i - lng + 1 of strng = " ") or (char lng - i + 1 of strng = RETURN) then
- nothing()
- next repeat
- end if
- exit repeat
- end repeat
- return chars(strng, start, lng - i + 1)
- end
-