If you don't reseed the random number generator you'll always get the same
"random" numbers. To reseed the generator, use the Randomize command. To
then pull a record, create a number from the random number received that is
between the lowest and highest record ID number (inclusively) in the
recordset and move to that record.
The Rnd function returns a number >=0 And <1. To get a number in the range
you are looking for, there is a formula in the help file.
Int((upperbound - lowerbound + 1) * Rnd + lowerbound)
--
Wayne Morgan
MS Access MVP
"Ken Gray" <ke*****@speed-mail.co.uk> wrote in message
news:41**************@news.ispserve.co.uk...
Hi all
Anyone help me find a way of randomly selecting a record from a table
for display on a form. Do I need to somehow re-seed the random
generator?
I am sure there must be an easy, simple way but it has me foxed!
Hoping someone can help
Regards