|
-
September 24th, 1999, 02:31 AM
#1
Simple dumb string question
I have a string that will always be 75 spaces then a url, i.e.
"(insert 75 spaces here)www.hotmail.com"
My question is how can i take those spaces out without refuring to the url, since it will be different everytime and may or may not have http:// or www. ?
Thanks in Advance.
Ele
-
September 24th, 1999, 02:51 AM
#2
Re: Simple dumb string question
Hi
How about something like :
'
' sUrl is your string with 75 spaces then a Url
'
Dim sTemp as string
If len(sUrl) > 75 then
sTemp = Right$(sUrl, len(sUrl) - 75)
sUrl = sTemp
End If
Chris Eastwood
CodeGuru - the website for developers
http://codeguru.developer.com/vb
-
September 24th, 1999, 05:32 AM
#3
Re: Simple dumb string question
Hi!
I think the solution given by Chris Eastwood is ok, still one more solution
to this ,is to use ltrim(sting name), which will clear all the left
whitespaces swithout disturbing the url.
thanks.
manmath
-
September 24th, 1999, 05:59 AM
#4
Re: Simple dumb string question
If your trying to strip all of the spaces off of the left side of a string try the Ltrim$() function.
-
September 24th, 1999, 07:34 AM
#5
Re: Simple dumb string question
Wont Just Simple pain Trim(Str) work which can trim all the white spaces trailing and leading as well.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|