Michael Clease
28-05-2007, 10:57
Not happy with this but its a start.
' Usage of the LTRIM$ Keyword example
' Usage of the RTRIM$ Keyword example
' Usage of the TRIM$ Keyword example
' Usage Of the TRIMFULL$ Keyword
'
' Written by Abraxas
DIM MyOLDString as String value "HELLO WORLD"
DIM MyOLD2String as string value " A B C D E F "
DIM MyLTRIMString as string
DIM MyRTRIMString as string
DIM MyTRIMString as string
DIM MyTRIMFULLString as string
DIM sMsg as string
MyLTRIMString = LTRIM$(MyOLDString, any "HELLO")
MyRTRIMString = RTRIM$(MyOLDString, any "WORLD")
MyTRIMString = TRIM$(MyOLDString , any "HEL")
MyTRIMFULLString = TRIMFULL$(MyOLD2String)
sMsg += "Normal " & MyOLDString & $CRLF & $CRLF
sMsg += "LTRIM$ " & MyLTRIMString & $CRLF & $CRLF
sMsg += "RTRIM$ " & MyRTRIMString & $CRLF & $CRLF
sMsg += "TRIM$ " & MyTRIMString & $CRLF & $CRLF
sMsg += "TRIMFULL$ " & MyTRIMFULLString & $CRLF & $CRLF ' spaces removed
MsgBox 0, sMsg
' Usage of the LTRIM$ Keyword example
' Usage of the RTRIM$ Keyword example
' Usage of the TRIM$ Keyword example
' Usage Of the TRIMFULL$ Keyword
'
' Written by Abraxas
DIM MyOLDString as String value "HELLO WORLD"
DIM MyOLD2String as string value " A B C D E F "
DIM MyLTRIMString as string
DIM MyRTRIMString as string
DIM MyTRIMString as string
DIM MyTRIMFULLString as string
DIM sMsg as string
MyLTRIMString = LTRIM$(MyOLDString, any "HELLO")
MyRTRIMString = RTRIM$(MyOLDString, any "WORLD")
MyTRIMString = TRIM$(MyOLDString , any "HEL")
MyTRIMFULLString = TRIMFULL$(MyOLD2String)
sMsg += "Normal " & MyOLDString & $CRLF & $CRLF
sMsg += "LTRIM$ " & MyLTRIMString & $CRLF & $CRLF
sMsg += "RTRIM$ " & MyRTRIMString & $CRLF & $CRLF
sMsg += "TRIM$ " & MyTRIMString & $CRLF & $CRLF
sMsg += "TRIMFULL$ " & MyTRIMFULLString & $CRLF & $CRLF ' spaces removed
MsgBox 0, sMsg