+ Reply to Thread
Results 1 to 2 of 2

random numbers

  1. #1
    Registered User
    Join Date
    12-11-2006
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2007
    Posts
    86

    random numbers

    I have a column that has roughly 2000 entries in it. Each entry is made up of 3 letters and 9 numbers. Is there a peice of code that I could use that will allow me to randomly select 15 -20 of these enties and return them to a different section of the page?

    Thank you.

  2. #2
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,885
    If your entries are in column A, for example, you could use this in b1:b15:

    =INDIRECT("a"&RANDBETWEEN(1,2000))

    Because this uses 'RANDBETWEEN', if anything on your sheet triggers a recalculation b1:b15 will change, so you may want to copy and pastespecial>values after these formulas randomly generate their values. (Of course, when you do the paste, it will paste the values you copied, but those formulas in B1:B15 will recalculate again.)

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1