Code subject: remove space ,trim strings from left side ,right side ,both.
Posted: Sat Apr 09, 2011 12:19 am
Joined: Tue Mar 27, 2007 10:55 pm Posts: 2272 Location: Earth Has thanked: 39 time Have thanks: 61 time
Remove spaces from string in ASP , trim strings.
Code:
<% Dim strObj, newStrObj notice white spaces . strObj =" My Name is Tom " Response.Write("String before trim ="& strObj) newStrObj = LTrim(strObj) Response.Write("Left trim:String after ="& newStrObj) newStrObj = RTrim(strObj) Response.Write("Right trim:String after ="& newStrObj) newStrObj = Trim(strObj) Response.Write("Both sides trim:String after ="& newStrObj)
%>
_________________ Currenlty programming with : java , html , php , and javascript . (OCJP-6 certified )