RTrim Function

αž›αž»αž”β€‹αžŠαž€β€‹αžƒαŸ’αž›αžΆβ€‹αž“αŸ…β€‹αž…αž»αž„β€‹αž“αŸƒβ€‹αž€αž“αŸ’αžŸαŸ„αž˜β€‹αžαŸ’αžŸαŸ‚β€‹αž’αž€αŸ’αžŸαžšΒ αŸ”

αž˜αžΎαž›β€‹αž•αž„β€‹αžŠαŸ‚αžš αŸ– αž’αž“αž»αž‚αž˜αž“αŸ LTrim

Syntax:


RTrim (Text As String)

Return value:

αžαŸ’αžŸαŸ‚β€‹αž’αž€αŸ’αžŸαžš

Parameters:

αž’αžαŸ’αžαž”αž‘ αŸ– αž€αž“αŸ’αžŸαŸ„αž˜β€‹αžαŸ’αžŸαŸ‚β€‹αž’αž€αŸ’αžŸαžšβ€‹αžŽαžΆβ€‹αž˜αž½αž™Β αŸ”

Error codes:

5 αž€αžΆαžšβ€‹αž αŸ…β€‹αž”αŸ‚αž”αž”αž‘β€‹αž˜αž·αž“β€‹αžαŸ’αžšαžΉαž˜αžαŸ’αžšαžΌαžœ

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!