TrimRight
Previous  Top  Next

Prototype

StrOutput:=TrimRight(strInput)

Description

It returns a string similar to the shown one without final spaces, if existen.

Parameters

StrInput
: input string.

Returned value

StrOutput
: output string.

Notes

None.

Example

// It opens a text file
UnFile:=('c:\documents\letter.txt',false);

// It reads a line from file
text:=TextFileReadln(UnFile);

// It shows a message with the read text
ApplicationLog(_CurrentAgent,'File contains the following text: ' + text);

// It returns the string without final spaces.
NewText=TrimRight(text);

// It shows a message with the modified read text 
ApplicationLog(_CurrentAgent,'Here it is the modified text : ' + NewText);

// It closes the file
FileClose(UnFile);