+ Reply to Thread
Results 1 to 8 of 8

Trying to fill in empty blank cells

  1. #1
    Registered User
    Join Date
    03-04-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    16

    Trying to fill in empty blank cells

    I've got a spreadsheet that has Gender, Ethnicity, Birthdate, Age, Year Joined, and Age Group. There are a number of cells where people chose not to share that information.

    For both Age and Age Group, I created formulas to figure those out.

    For Birthdate, if they didn't give an age, Excel defaults to 120 but I would like to write a formula that says "if there is no date in Birthdate, this cell (Age) should equal Not Given. The same is true for Ethnicity and Gender. I thought that I could use an if(isblank) formula for those two rows, but it's not working. I tried =if(isblank(C9),"Not Given", ""), but that doesn't work. As you'll see in my example, I hard coded Not Given for Ethnicity, but that's not a good fix.

    Any help is appreciated.

    Chip
    Attached Files Attached Files
    Last edited by RCMjr; 07-02-2020 at 12:01 PM.

  2. #2
    Valued Forum Contributor
    Join Date
    04-24-2020
    Location
    Woodbridge, VA
    MS-Off Ver
    2016
    Posts
    434

    Re: Trying to fill in empty blank cells

    Try this in D2 and copy down:

    =IF(C2<>"",DATEDIF(C2,TODAY(), "Y"),"Not Given")

  3. #3
    Valued Forum Contributor
    Join Date
    04-24-2020
    Location
    Woodbridge, VA
    MS-Off Ver
    2016
    Posts
    434

    Re: Trying to fill in empty blank cells

    Also try this in F2 and copy down:

    =IF(D2<>"Not Given",LOOKUP(D2,{0,"0-19";20,"20-29";30,"30-39";40,"40-49";50,"50-59";60,"60-69";70,"70-79"}),"Not Given")

  4. #4
    Registered User
    Join Date
    03-04-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    16

    Re: Trying to fill in empty blank cells

    mikeava - what does <> do? That's new to me. How do I read that?

  5. #5
    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,830

    Re: Trying to fill in empty blank cells

    This means "not equal to":

    =IF(D2 is NOT equal to "Not Given", ...
    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.

  6. #6
    Valued Forum Contributor
    Join Date
    04-24-2020
    Location
    Woodbridge, VA
    MS-Off Ver
    2016
    Posts
    434

    Re: Trying to fill in empty blank cells

    It means not equal to

    So for the formula in D2, it looks at C2 and if it is not equal to blank ("") then perform your original formula, otherwise write Not Given.

  7. #7
    Registered User
    Join Date
    03-04-2013
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    16

    Re: Trying to fill in empty blank cells

    Thanks for helping me out.

  8. #8
    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,830

    Re: Trying to fill in empty blank cells

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

+ 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. [SOLVED] Add IF IS BLANK to formula so blank cells stay empty
    By Hedy in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-05-2020, 05:25 PM
  2. Replies: 5
    Last Post: 11-17-2017, 04:43 PM
  3. Pivot table in blank cells it says blank.... i want it empty
    By appell in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 03-27-2014, 09:43 AM
  4. [SOLVED] Macro to fill blank cells in column A based on non-blank cells
    By ktalamantez in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-28-2014, 02:47 PM
  5. Fill blank cells with data directly above that blank cell
    By gibson2503 in forum Excel General
    Replies: 3
    Last Post: 06-05-2013, 10:07 AM
  6. How to color-fill blank cells, then once data is entered cell is no-fill
    By hatemail13 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-28-2013, 07:57 PM
  7. Replies: 5
    Last Post: 01-12-2013, 12:16 AM

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