|
-
Jan 3rd, 2000, 10:33 PM
#1
Thread Starter
Member
How to get the length of string?
for egzample i have "WholyGvakamoly"
and i need to get number 14 (the length)
-
Jan 3rd, 2000, 10:55 PM
#2
Use Len(string)
It will return the length of a string.
-
Jan 3rd, 2000, 11:01 PM
#3
Thread Starter
Member
Well i tried that before
and VB says "indentifier expected" or something like that
could anyone please write the sample code
-
Jan 3rd, 2000, 11:14 PM
#4
Frenzied Member
did you miss off a " ?
msgbox len("WholyGvakamoly")
works
as does
dim strTemp as string
stremp = "WholyGvakamoly"
msgbox len(strtemp)
------------------
Mark Sreeves
Analyst Programmer
[email protected]
A BMW Group Company
-
Jan 3rd, 2000, 11:19 PM
#5
Hyperactive Member
Hi,casparas!
Put command button and Text box on your form:
Private Sub Command1_Click()
Dim YourString As String
Dim LengthOfYourString As Integer
YourString = "WholyGvakamoly"
LengthOfYourString = Len(YourString)
Text1 = LengthOfYourString
End Sub
After you click the button,you'll see in text box - 14
Good luck.
Larisa
-
Jan 4th, 2000, 01:01 AM
#6
Thread Starter
Member
Thank you very much that's exactly what i needed
-Casparas
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
|