- Code: Select all
set someString to value of variable "CID_Display_Name"
set noTrailingSpacesString to removeTrailingSpaces(someString)
on removeTrailingSpaces(theString)
repeat while theString ends with space
set theString to text 1 thru -2 of theString
end repeat
--return theString
set the value of variable "CID_Display_Name" to theString
end removeTrailingSpaces
Appreciate any help.
Thanks,
Carl