# Trim

> Kalipso Studio 6.1 documentation · https://doc.sysdevmobile.com/kalipso/6.1/documentation/expressions/functions/string-functions/trim
>
> Trim removes the spaces at the beginning, the end or both sides of a string, chosen with the Trim Left and Trim Right flags.

This Function returns a _\<string>_, which is the specified **Source string** with all the spaces at beginning and ending removed.

### Parameters

* **Source string** _\<string> -_ String to remove the spaces from.
* **Trim Left** _\<boolean> -_ Removes spaces from the left side of the **Source string**?
* **Trim Right** _\<boolean> -_ Removes spaces from the right side of the Source string?

### Examples

* _Example 1_

"<" + Trim(" Kalipso ", YES, YES) + ">"\
**Result** = \<Kalipso>

* _Example 2_

"<" + Trim(" Kalipso ", YES, NO) + ">"\
**Result** = \<Kalipso >

* _Example 3_

"<" + Trim(" Kalipso ", NO, YES) + ">"\
**Result** = < Kalipso>

* _Example 4_

"<" + Trim(" Kalipso ", NO, NO) + ">"\
**Result** = < Kalipso >
