[fpc-pascal] Trim repeated whitespace from a string

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Sat May 27 00:06:06 CEST 2006

On 5/26/06, Cox, Stuart TRAN:EX <Stuart.Cox at gov.bc.ca> wrote:
> The __CvtStr function used the _REM_LEAD_WHITE_STR +

For this you can just use the Trim function.


This looks easy to implement. You can just create your own function for this.

for i := 0 to Length(Str) do
  If last character was a space and Str[i] is a space, take that character off.

Felipe Monteiro de Carvalho

More information about the fpc-pascal mailing list