|
-
Jul 4th, 2003, 03:09 PM
#1
Thread Starter
Lively Member
Problem with do.... loop
Code:
x = 0
Do Until x = users.Length
'MsgBox("" & i & " " & x & " " & uid & "")
If users(x) = uid Then
spam2 = (spam2.Substring(spam2.IndexOf(inner)))
MsgBox("MULTIPLE PERSON DETECTED")
Exit Do
Else
If users(x) = users.Length Then
Exit Do
End If
End If
x = x + 1
Loop
using that do statement, im searching through an array, is seems to work because it picks up about the first 2 doubles, anyone know what i can do to fix this? or if theres a a problem with the syntax?
-
Jul 4th, 2003, 03:44 PM
#2
So it works, but you don't want it to?
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Jul 4th, 2003, 04:04 PM
#3
Yes what exactly is the question?
It might be easier if you used a for each loop also:
VB Code:
Dim user As Object 'since your code doesn't show its type
For Each user in users
If user=uid Then
spam2 = (spam2.Substring(spam2.IndexOf(inner)))
MsgBox("MULTIPLE PERSON DETECTED")
Exit For
End If
Next
-
Jul 4th, 2003, 09:34 PM
#4
Thread Starter
Lively Member
Hmmm, sorry, power just came back...
now, that part of the code works finds like 2 users, but then after that, it just doesnt seem to search the rest of the array
Edit: users is an array
-
Jul 5th, 2003, 12:40 AM
#5
Originally posted by Azkar
Hmmm, sorry, power just came back...
now, that part of the code works finds like 2 users, but then after that, it just doesnt seem to search the rest of the array
Edit: users is an array
hehe power came back? hmmmm!!
you should explain more. People don't always give you nice answers if you don't fully explain what you're talking about
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
-
Jul 5th, 2003, 08:50 AM
#6
Frenzied Member
Originally posted by MrPolite
hehe power came back? hmmmm!!
Not that funny dude, i can guess where azkar comes from and there going out the electricity power is not at all unusual.
'Heading for the automatic overload'
Marillion, Brave, The Great Escape, 1994
'How will WE stand the FIRE TOMORROW?'
Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979
-
Jul 5th, 2003, 10:11 AM
#7
Thread Starter
Lively Member
right, big storm over here
-
Jul 5th, 2003, 02:33 PM
#8
-
Jul 5th, 2003, 02:54 PM
#9
Thread Starter
Lively Member
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
|