LTrim Function

แƒกแƒขแƒ แƒ˜แƒœแƒ’แƒฃแƒšแƒ˜ แƒ’แƒแƒ›แƒแƒกแƒแƒฎแƒฃแƒšแƒ”แƒ‘แƒ˜แƒ“แƒแƒœ แƒแƒ›แƒแƒ˜แƒฆแƒ”แƒ‘แƒก แƒงแƒ•แƒ”แƒšแƒ แƒฌแƒแƒ›แƒซแƒฆแƒ•แƒแƒœแƒ”แƒ‘แƒฃแƒš แƒฐแƒแƒ แƒก.

Syntax:


LTrim (Text As String)

Return value:

แƒกแƒขแƒ แƒ˜แƒฅแƒแƒœแƒ”แƒ‘แƒ˜

Parameters:

แƒขแƒ”แƒฅแƒกแƒขแƒ˜: แƒœแƒ”แƒ‘แƒ˜แƒกแƒ›แƒ˜แƒ”แƒ แƒ˜ แƒกแƒขแƒ แƒ˜แƒœแƒ’แƒฃแƒšแƒ˜ แƒ’แƒแƒ›แƒแƒกแƒแƒฎแƒฃแƒšแƒ”แƒ‘แƒ.

แƒ’แƒแƒ›แƒแƒ˜แƒงแƒ”แƒœแƒ”แƒ— แƒ”แƒก แƒคแƒฃแƒœแƒฅแƒชแƒ˜แƒ แƒกแƒขแƒ แƒ˜แƒœแƒ’แƒฃแƒšแƒ˜ แƒ’แƒแƒ›แƒแƒกแƒแƒฎแƒฃแƒšแƒ”แƒ‘แƒ˜แƒก แƒ“แƒแƒกแƒแƒฌแƒงแƒ˜แƒกแƒจแƒ˜ แƒฐแƒแƒ แƒ”แƒ‘แƒ˜แƒก แƒฌแƒแƒกแƒแƒจแƒšแƒ”แƒšแƒแƒ“.

Error codes:

D'oh! You found a bug (text/sbasic/shared/00000003.xhp#err5 not found).

Example:


Sub ExampleSpaces
Dim sText2 As String,sText As String,sOut As String
    sText2 = " <*Las Vegas*> "
    sOut = "'"+sText2 +"'"+ Chr(13)
    sText = Ltrim(sText2) ' sText = "<*Las Vegas*> "
    sOut = sOut + "'"+sText +"'" + Chr(13)
    sText = Rtrim(sText2) ' sText = " <*Las Vegas*>"
    sOut = sOut +"'"+ sText +"'" + Chr(13)
    sText = Trim(sText2) ' sText = "<*Las Vegas*>"
    sOut = sOut +"'"+ sText +"'"
    MsgBox sOut
End Sub

Please support us!