Choose where you’d like to start

ltrim

Overview

The ltrim function removes all the extra white spaces (if any) inserted before the text and returns the trimmed text.

Return Type

  • TEXT

Syntax

<variable> = <input_text>.ltrim();

(OR)

<variable> = ltrim(<input_text>);

where,

ParameterData typeDescription
<variable>TEXTVariable that will hold the trimmed text
<text1>TEXT

The input text whose leading white spaces need to be removed

Examples

 text = "   Zoho";
 result = text.ltrim(); // returns "Zoho"
 
​ text_size = text.length(); // returns 7
 result_size = result.length(); // returns 4
 
Note: The length built-in function returns the number of characters in the input text.

Get Started Now

Execute