Trim
Trim whitespace from the beginning and end of a string
Method Signature
Trim(string=[string])
Arguments
Argument
Type
Required
Description
Default
string
string
true
The string to trim
Examples
Trim
">" & trim( " BLDocs " ) & "<";
Result: >BLDocs<
Additional Examples
// create variable with a string of text that has leading and trailing spaces
foo = " Hello World! ";
// output variable
writeDump( "-" & foo & "-" );
// output variable without leading and trailing spaces
writeDump( "-" & Trim( foo ) & "-" );
Related
Last updated
Was this helpful?