View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default RandomNumber Generator

You want a random shuffle of the digits 0 - 9

in A1:I1 put in the digits 0 to 9
in A2:I2 put in the formula
=rand()

select A1:I2 and do Data=Sort, select options and left to right

then select row2 as the key. (ascending or descending - your choice)

This will sort your numbers. Also, the random numbers in column 2 will be
regenerated so you are ready to repeat the sort for a new random
organization.

--
Regards,
Tom Ogilvy

"Pete" wrote in message
...
I want to randomly pick a number between 1000000000 and 9999999999 with a
couple of options to contend with.

First: I don't ever want to pick the 1234567890 and 9876543210.
Second: if the number generated has any repeat numbers then I want to

regect
it and select another one. IE # 1123421456 would be rejected because of

the
repeatitive 1's.
Third: After the number is set with no repeat numbers I want to seperate

it
into their own colums for frther minipulation.

And ideas.
Thanks for you help.
--
Pete