+ Reply to Thread
Results 1 to 5 of 5

randomly selecting a cell from a range

  1. #1
    Registered User
    Join Date
    10-13-2008
    Location
    China
    Posts
    12

    randomly selecting a cell from a range

    I need a cell to display the (text) content of 1 of 25 cells.

    example: I have text content in all cells ranging A1:A25

    I want cell B1 to display the content of 1 of these at random.

    is there a function for this or do I need to use a macro?

    all help welcome,

    thankyou!
    Last edited by snuiter; 10-14-2008 at 12:30 AM.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,607
    You can use a helper cell to create your random address. In C1:

    Please Login or Register  to view this content.
    Then in B1:
    Please Login or Register  to view this content.
    Pressing F9 to recalc will cycle through A1:A25 randomly
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    10-13-2008
    Location
    China
    Posts
    12
    heheey that worked

    awesome.. thanks!

  4. #4
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,885
    For what it's worth, you could do it without the helper cell in C1, by simply using this in B1:

    =INDIRECT("A"&RANDBETWEEN(1,25))

  5. #5
    Registered User
    Join Date
    10-13-2008
    Location
    China
    Posts
    12
    @pjoaquin

    aah yes that makes sense

    thanks *cleaner is better*

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Variable Cell Range
    By agnewt in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-01-2008, 03:19 PM
  2. Selecting One Cell Copies Range
    By smell_fire in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 08-28-2008, 05:55 PM
  3. Selecting and Copying a Cell or a Range of Cells from One or More Files or Worksheets
    By Tyler Peco in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-27-2008, 03:55 PM
  4. using cell content to reference a worksheet tab name in second workbook
    By Conor in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-29-2007, 09:32 AM
  5. Preventing users from selecting a cell in a range
    By mike.magill in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-11-2007, 03:44 AM

Tags for this Thread

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