[RESOLVED] My random numbers ain't!
I have a selection of arrays, and I want to pick a single item out of them at random. The problem is that when I run my code the sequence in which my "random" selections appear is the same. This is the code I am using:
Code:
Sub RandomTexts()
For i = 1 To 7
destin1(i) = Sheets("mutable 1").Cells(2 + i, 2)
Next i
strDestin1 = destin1(Int(7 * Rnd) + 1)
End Sub
I hope there is a smiple solution. Thanks for your help.
Re: My random numbers ain't!
If you look at the help for Rnd you will see that behaviour is expected, and the way to fix it is easy... just run the following line of code once (perhaps in the Workbook_Open event):
Re: My random numbers ain't!
Thanks for that. Problem solved. Project to subtly subvert a middle class Christmas custom is back on track!!