Field-Map Scripting

4.1.2.4 Trim

Trim function


Prototype:

function Trim: (const s: string): string;

Description:

Returns a copy of string s with all leading and trailing white-spaces removed.

Syntax:

variable := Trim(s);


Part

Description


variable

A variable declared as a string.


s

String containing white-spaces to be removed.

Return value:

String with leading and trailing white-spaces removed.



 Example:


var

 s_var: string;


begin

 s_var:=Trim('   Hello   ');     // Returns {Hello}

 ShowMessage(s_var)

end.


Output in Field-Map Data Collector:


See also:

Format; LZero; Delete; Trim; TrimLeft; TrimRight; SameText; StringReplace; DeFormat1-10; GetFieldCountFromString;GetFieldFromString; IndexOfField; SortNumericSequence