+ Reply to Thread
Results 1 to 12 of 12

Max returning 0...I want to return blank

  1. #1
    Forum Contributor
    Join Date
    10-28-2003
    Location
    Happyville, USA
    MS-Off Ver
    365
    Posts
    294

    Max returning 0...I want to return blank

    Hello all. Thank you in advance for your help.

    I am having any issue with my Max formula. The formula is
    HTML Code: 
    .

    It is returning me the highest value as it should. But if there is no value in the three cells it is returning 0. How do I get it to return blank. I have been trying various array formulas but nothing seems to work.

    I'll look forward to your replies.

    Thanks

    Eddie

  2. #2
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2021
    Posts
    5,987

    Re: Max returning 0...I want to return blank

    Try this ...

    =IF(Max(H1339:J1339)=0,"",Max(H1339:J1339))

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Max returning 0...I want to return blank

    Wow !! Looking at your Join date, you must have been one of the very earliest to join this Forum.

    You could do it like this:

    =IF(COUNTIF(H1339:J1339,"")=3,"",MAX(H1339:J1339))

    Hope this helps.

    Pete

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Max returning 0...I want to return blank

    @Phuocam

    Zero might be a valid number for MAX to return.

    Pete

  5. #5
    Forum Contributor
    Join Date
    10-28-2003
    Location
    Happyville, USA
    MS-Off Ver
    365
    Posts
    294

    Re: Max returning 0...I want to return blank

    Thank you so much. This worked perfectly.

  6. #6
    Forum Contributor
    Join Date
    10-28-2003
    Location
    Happyville, USA
    MS-Off Ver
    365
    Posts
    294

    Re: Max returning 0...I want to return blank

    I have been around a while.

  7. #7
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,318

    Re: Max returning 0...I want to return blank

    As Pete points out, if zero is a valid number then you could just mask it with a custom format...

    Custom Format
    • Right click cell (or Ctrl + 1)
    • Format Cells
    • Number
    • Custom
    • Type: 0;;;
    HTH
    Regards, Jeff

  8. #8
    Forum Contributor
    Join Date
    10-28-2003
    Location
    Happyville, USA
    MS-Off Ver
    365
    Posts
    294

    Re: Max returning 0...I want to return blank

    Thank you Jeffrey for your help.

  9. #9
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,318

    Re: Max returning 0...I want to return blank

    You are very welcome. We are happy to help.

  10. #10
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2021
    Posts
    5,987

    Re: Max returning 0...I want to return blank

    Or try this ...

    =IF(COUNT(H1339:J1339),MAX(H1339:J1339),"")

  11. #11
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Max returning 0...I want to return blank

    As I understand it, the OP might have 3 blank cells - in this case he wants to see a blank as the result. However, if one or more cells contains a number (which could be zero), then you would want to see the result, so masking the zero or setting the cell to "" if the result is zero does not fully accomplish that.

    Pete

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

    Re: Max returning 0...I want to return blank

    Here's another one...

    =IF(COUNT(H1339:J1339),Max(H1339:J1339),"")
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

+ 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] Cells in a range are all not blank, return maximum value (date), If 1 blank return 0
    By Matt1998 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-19-2016, 11:14 AM
  2. Return first non blank cell (cells have formulas that return blank)
    By BG1983 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-05-2016, 04:06 PM
  3. [SOLVED] Reference cell formula returning 0 when BLANK, need BLANK to show
    By williamc in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 03-31-2016, 04:23 PM
  4. Please help, Returning a blank when cell is blank
    By BenHarris in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 02-25-2015, 10:55 PM
  5. Replies: 2
    Last Post: 06-21-2012, 04:51 PM
  6. Returning a blank if cell is blank
    By Slongy in forum Excel General
    Replies: 3
    Last Post: 06-05-2009, 05:05 AM
  7. Replies: 3
    Last Post: 11-22-2007, 07:53 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