+ Reply to Thread
Results 1 to 6 of 6

Hide/Show Zeros when using a formula

  1. #1
    Registered User
    Join Date
    02-18-2014
    Location
    Alberta, Canada
    MS-Off Ver
    Excel 2007
    Posts
    12

    Hide/Show Zeros when using a formula

    Hi, I want to have a formula that converts a Yes answer to a percentage - let's say 25% for now.

    =IF(F6="Yes",0.25,0)+IF(G6="Yes",0.25,0)+IF(H6="Yes",0.25,0)+IF(I6="Yes",0.25,0)

    This works for me - it totals up to 100% if all yes across 4 cells. I want to hide zero's where the cells haven't been populated yet with a yes or a no. BUT if all four cells are populated with a no or one cell has a no and the rest are empty, then I want the zero to be displayed - 0%.

    I can only manage to figure out how to hide ALL zero's or have them all show.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Hide/Show Zeros when using a formula

    =IF(SUM(COUNTIF(F6:I6, {"yes","no"})), SUMPRODUCT((F6:I6 = "yes")*0.25), "")
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    02-18-2014
    Location
    Alberta, Canada
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Hide/Show Zeros when using a formula

    That works awesome, thank you!

    Different question - is there a way to format the text so all users are entering the text Yes or No the same. So we dont get variations; YES Yes yes YeS etc?

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Hide/Show Zeros when using a formula

    Data Validation > Data Validation, Settings tab, Allow: List, Source: Yes,No

  5. #5
    Registered User
    Join Date
    02-18-2014
    Location
    Alberta, Canada
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Hide/Show Zeros when using a formula

    I appreciate your quick response and help, thank you!

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Hide/Show Zeros when using a formula

    You're welcome.

+ 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] =MID formula doesn't show leading zeros
    By k1989l in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 10-29-2015, 04:53 PM
  2. Replies: 1
    Last Post: 01-27-2013, 08:06 PM
  3. hide zeros and NA#'s from result of Index/match formula
    By merlyn45 in forum Excel General
    Replies: 2
    Last Post: 05-10-2012, 02:10 PM
  4. Hide/Show Formula
    By Battledeck in forum Excel General
    Replies: 1
    Last Post: 04-02-2012, 01:55 PM
  5. HIDE ZEROS IN CHART - Hide rows of cells that equals zero
    By sweedey in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-09-2011, 08:18 PM
  6. [SOLVED] How do I hide a formula so it will not show on the spreadsheet?
    By Brenda in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-05-2006, 09:20 AM
  7. Replies: 2
    Last Post: 10-02-2005, 11:05 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