Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Neat code but why did you suggest making it a worksheet macro rather than a
general one? best wishes -- Bernard V Liengme Microsoft Excel MVP http://people.stfx.ca/bliengme remove caps from email "Mike H" wrote in message ... helen, This will put 50 unique random integers in column A. Right click your sheet tab, view code and paste this in and run it Sub No_Repeats() Dim MyRange As Range Set MyRange = Range("A1:A50") For Each c In MyRange Do c.Value = Int((9999 * Rnd) + 1) Loop Until WorksheetFunction.CountIf(MyRange, c.Value) < 2 Next End Sub Mike "helen" wrote: I would like to know how to generate some quick random numbers in order to use for demo purposes. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Generate random numbers | Excel Discussion (Misc queries) | |||
using excel generate random numbers 1 to 52 without repeating | Excel Worksheet Functions | |||
How do I generate random lottery numbers in Excel? | Excel Worksheet Functions | |||
How do I generate random numbers using dates in excel? | Excel Worksheet Functions | |||
generate random numbers | Excel Worksheet Functions |