Closed Thread
Results 1 to 7 of 7

Skip Blank cells while using "Randbetween" function

  1. #1
    Forum Contributor
    Join Date
    09-16-2014
    Location
    Hyderabad
    MS-Off Ver
    MS Office 2021
    Posts
    346

    Skip Blank cells while using "Randbetween" function

    Hello All!!

    I am using the below formula to select a random cell from the list A1 to A26. This range has few blank cells, hence I want to ignore them and only return cells with value whenever excel calculates.

    Anyhelp will please.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  2. #2
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Skip Blank cells while using "Randbetween" function

    Try this Array Formula which requires confirmation with Ctrl+Shift+Enter instead of Enter alone.

    Please Login or Register  to view this content.
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Skip Blank cells while using "Randbetween" function

    Here is a User Defined Function that will do what you want also.

    Please Login or Register  to view this content.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Forum Contributor
    Join Date
    09-16-2014
    Location
    Hyderabad
    MS-Off Ver
    MS Office 2021
    Posts
    346

    Re: Skip Blank cells while using "Randbetween" function

    Thanks a ton to all.

    They worked for me.

  5. #5
    Registered User
    Join Date
    05-03-2016
    Location
    Ulaanbaatar
    MS-Off Ver
    2013
    Posts
    1

    Re: Skip Blank cells while using "Randbetween" function

    hi. how to INdex to skip blank use random and if
    123.png

  6. #6
    Registered User
    Join Date
    03-08-2016
    Location
    Amman, Jordan
    MS-Off Ver
    2013
    Posts
    32

    Re: Skip Blank cells while using "Randbetween" function

    Hi,
    I have the below formula in excel, and am facing problem to skip empty cells while random selection
    Range("C9").Formula = "=INDEX('Sorted Names'!$H$3:$H$5,RANDBETWEEN(1,COUNTA('Sorted Names'!$H$3:$H$5)))"

    Any body can help?

    Thanks

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,460

    Re: Skip Blank cells while using "Randbetween" function

    Unfortunately your post does not comply with Rule 2 of our Forum RULES. Do not post a question in the thread of another member -- start your own thread.

    If you feel an existing thread is particularly relevant to your need, provide a link to the other thread in your new thread.

    Old threads are often only monitored by the original participants. New threads not only open you up to all possible participants again, they typically get faster response, too.

    Thread closed.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

Closed Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] IF function returning blank cells as 0 instead of a blank even though "" is being used
    By scootty83 in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 3
    Last Post: 06-02-2015, 02:47 AM
  2. [SOLVED] Keeping particular cell blank if the related cells show "0" or "blank"
    By Anuru in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-24-2014, 05:30 AM
  3. [SOLVED] Replace all BLANK cells in column with header title "Balance" to "0"
    By ks100 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-21-2014, 09:25 AM
  4. [SOLVED] How to USE """"" cells count """"" change font color
    By austin123456 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-09-2013, 06:14 AM
  5. Replies: 3
    Last Post: 02-16-2011, 02:55 PM
  6. "Left" function - How to skip over a full stop in text
    By Grimace in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-20-2010, 03:08 AM
  7. Replies: 3
    Last Post: 12-14-2006, 01:36 PM

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