+ Reply to Thread
Results 1 to 5 of 5

Exclude Empty Cells in a Data Validation List

Hybrid View

  1. #1
    Registered User
    Join Date
    01-14-2013
    Location
    Jupiter
    MS-Off Ver
    Excel 2013
    Posts
    78

    Exclude Empty Cells in a Data Validation List

    I have a range that I want to make data validation list out of. The range has a lot of blank cell in it. I want the data validation list to only include the cell that have a value in them. The cells have formulas that go off another sheet, so I can't just delete the empty cells. I have attached a workbook if you want to see.
    Attached Files Attached Files

  2. #2
    Forum Expert Tinbendr's Avatar
    Join Date
    06-26-2012
    Location
    USA
    MS-Off Ver
    Office 2010
    Posts
    2,138

    Re: Exclude Empty Cells in a Data Validation List

    Not an easy solution for a validation list. See this article.
    David
    (*) Reputation points appreciated.

  3. #3
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Exclude Empty Cells in a Data Validation List

    Pl see the file.
    Attached Files Attached Files

  4. #4
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Exclude Empty Cells in a Data Validation List

    You would have to extract the data to a new range excluding the empty cells then use this new range as the source for the drop down list.

    What version of Excel does this have to work in? The sample file is in *.xlsx format but your user profile says you're using Excel 2003.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  5. #5
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229

    Re: Exclude Empty Cells in a Data Validation List

    If the list (with blanks) is in A1:A100, you can put the formula
    =INDEX(A:A, SMALL(IF($A$1:$A$100="",999,ROW($A$1:$A$100)), ROWS($1:1)),1)&""
    in B1. This should be entered as an array formula (Ctrl-Shift-Enter). The drag it down to B100. That should bring all the non-blank cells to the top and a validation list range of

    =$B$1:INDEX($B:$B, COUNTIF($B:$B, "> "), 1)

    will work for you. (the condition for the COUNTIF is "[greater than][space]")
    _
    ...How to Cross-post politely...
    ..Wrap code by selecting the code and clicking the # or read this. Thank you.

+ 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