G
Guest
I'm hoping someone can help me with a problem I'm having using the random
class. I need to return a "random" number between 0 and 15, so i did this
Dim r as new Random()
Return r.Next(0, 15)
When I run my application, I call this code 12 times, one right after
another, but it keeps retuning the same number. If I put a break point in
and step through the application, the code runs correctly and I get
different numbers. Anyone heard of this before?
Any help would be greatly appreciated.
Chris
class. I need to return a "random" number between 0 and 15, so i did this
Dim r as new Random()
Return r.Next(0, 15)
When I run my application, I call this code 12 times, one right after
another, but it keeps retuning the same number. If I put a break point in
and step through the application, the code runs correctly and I get
different numbers. Anyone heard of this before?
Any help would be greatly appreciated.
Chris