|
-
Nov 15th, 2001, 03:01 PM
#1
Thread Starter
Addicted Member
Substring
How to substring a string to specified length?
dim temp as string
temp = "Qre60200000"
I want to display in a message box like this
6020 0000.(There should be a space inbetween).How to do that/
Thanks.
-
Nov 15th, 2001, 03:46 PM
#2
Code:
tmp = "ABCxxxxxxxx"
temp = mid(temp,4)
temp = left(temp,4) & " " & mid(temp,5)
temp is now "xxxx xxxx"
-
Nov 15th, 2001, 03:49 PM
#3
tmp = "ABCxxxxxxxx"
temp = mid(temp,4)
temp = left(temp,4) & " " & mid(temp,5)
jim temp = "" check your spelling mister!
j/k
temp = "ABCxxxxxxxx"
temp = mid(temp,4,4) & " " & right(temp,4)
one less step
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
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
|