+ Reply to Thread
Results 1 to 6 of 6

Return Max Date or Blank

  1. #1
    Registered User
    Join Date
    07-29-2008
    Location
    FL
    MS-Off Ver
    XL 2007 & 2008
    Posts
    27

    Return Max Date or Blank

    I am currently using an array to return the MAX date value. This formula will enter 1/0/00 if the referenced cells are blank. I'd like the furmula to LEAVE THE CELL BLANK if the referenced cells are blank.

    {=MAX(IF(Bid_Circuits=$A45,Bid_Trim_Completed,""))}

    What would a good way to accomplish this be????



    Many, many thanks to all.
    Last edited by smninos; 12-09-2009 at 01:00 PM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Return Max Date or Blank

    Try

    =IF(Count(Bid_Circuits)=0,"",MAX(IF(Bid_Circuits=$A45,Bid_Trim_Completed,"")))
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Return Max Date or Blank

    Your post would imply you're returning dates - if so given we can assume 0 to never be a "valid" result you can simply apply a Custom Format to the cell(s) containing the Array of: [=0]"";m/d/yy

    The 0 outputs will thus appear and print as blank.

    Other than that you're looking at applying a pre-emptive COUNTIFS test I'd say.
    Last edited by DonkeyOte; 12-09-2009 at 10:41 AM. Reason: can't spell

  4. #4
    Registered User
    Join Date
    07-29-2008
    Location
    FL
    MS-Off Ver
    XL 2007 & 2008
    Posts
    27

    Re: Return Max Date or Blank

    NBVC, thank you but it seems that your formula doesn't function as desired UNLESS Donkeyote's custom format is applied which also works with my formula.

    I would like to accomplish leaving the cells blank without another array, but this will suffice if nothing else is available....

    Thanks to both of you!

  5. #5
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Return Max Date or Blank

    If Bid_Circuits is completely blank then the formula should work.

  6. #6
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Return Max Date or Blank

    NBVC, I suspect it's also important as to whether or not the Date field is blank for all instances of a given record ... hence the COUNTIFS suggestion

    I'm not sure why the Custom Format approach isn't viable... it would certainly be my preference for the sake of calculation overhead.

    EDIT:

    In hindsight a SUMIF should suffice in preference to COUNTIFS

    =IF(SUMIF(Bid_Circuits,$A45,Bid_Trim_Completed),MAX(IF(Bid_Circuits=$A45,Bid_Trim_Completed)),"")}
    Last edited by DonkeyOte; 12-09-2009 at 11:02 AM.

+ 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