Datagrid column of data with trailing spaces

Phil Davis revdev at pdslabs.net
Mon Jul 14 17:21:18 EDT 2014


put the dgText of grp "dgGrid" into tText
repeat for each line tLine in tText
     put word 1 to -1 of tLine & CR after tNewText
end repeat
delete last char of tNewText
set the dgText of grp "dgGrid" to tNewText

:-)
Phil Davis


On 7/14/14, 1:56 PM, Magicgate Software - Skip Kimpel wrote:
> Good afternoon,
>
> I have a datagrid and column 1 has trailing spaces in the data items that I
> need to get rid of.  The number of trailing spaces is never
> consistent.  Once again, I think regex will be my friend / worst enemy :)
>
> Suggestions on how to do this effectively?
>
> Thanks in advance for your input,
>
> SKIP
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>

-- 
Phil Davis





More information about the use-livecode mailing list