ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How do you randomly generate numbers in Excel 2007? (https://www.excelbanter.com/excel-discussion-misc-queries/260924-how-do-you-randomly-generate-numbers-excel-2007-a.html)

Steve Bedard

How do you randomly generate numbers in Excel 2007?
 
How do you randomly generate numbers from 1 to 84 without duplicates in Excel
2007?

מיכאל (מיקי) אבידן

How do you randomly generate numbers in Excel 2007?
 
1) Download and Install "MoreFunc" add-in.
http://www.download.com/Morefunc/300...-10423159.html
2) In cell A1 type: =MRAND(,1,84) and copy down all the way to A84 (incl.)
Micky


"Steve Bedard" wrote:

How do you randomly generate numbers from 1 to 84 without duplicates in Excel
2007?


Niek Otten

How do you randomly generate numbers in Excel 2007?
 
http://www.mcgimpsey.com/excel/udfs/randint.html

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"Steve Bedard" <Steve wrote in message
...
How do you randomly generate numbers from 1 to 84 without duplicates in
Excel
2007?



Mike H

How do you randomly generate numbers in Excel 2007?
 
Hi,

the question isn't clear but try this. Select the cells you want the numbers
in and run this code. Because you are in the range 1 to 84 you mest selevt 84
cells or less

Sub Unique_Rands()
Dim FillRange As Range
Set FillRange = Selection
For Each c In FillRange
Do
c.Value = Int((84 * Rnd) + 1)
Loop Until WorksheetFunction.CountIf(FillRange, c.Value) < 2
Next
End Sub
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.


"Steve Bedard" wrote:

How do you randomly generate numbers from 1 to 84 without duplicates in Excel
2007?


מיכאל (מיקי) אבידן

How do you randomly generate numbers in Excel 2007?
 
Well..., I don't know how much of a "gambler" you are - but as a "Gimmick"
you are invited to try the proposal in the picture.
Any cell - in range F1:F84 must be blank.
An "X" points that that value was generated more than once.
Cells A1, B1 and F1 should be copied down all the way until row 84.
http://img717.imageshack.us/img717/5083/nonamesi.png
Micky


"Steve Bedard" wrote:

How do you randomly generate numbers from 1 to 84 without duplicates in Excel
2007?



All times are GMT +1. The time now is 10:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com