Link to home
Start Free TrialLog in
Avatar of rickydoyle
rickydoyle

asked on

Trim Function

Is it possible to use a Trim function and a Ucase Function on the same line of code?  If so how?
Avatar of TSO Fong
TSO Fong
Flag of Sweden image

dim strStringOne
dim strStringTwo

strStringOne = "   HelLo TherE    "
strStringTwo = UCase(Trim(strStringOne))



This gives you "HELLO THERE" for strStringTwo.

Hope this helps -- b.r.t.
Avatar of HATCHET
HATCHET

rickydoyle,

You can conbine any number of functions together in the same line... including the mixture of your custom functions, VB standard functions, and API declared functions.  For example :

MyVariable = MyFunction(Left(Trim(TestVariable),2))

HATCHET
ASKER CERTIFIED SOLUTION
Avatar of mathies
mathies

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial