View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Claus Busch Claus Busch is offline
external usenet poster
 
Posts: 3,872
Default IF statement returns false when statment is True

Hi Don,

Am Wed, 3 Jun 2015 05:14:30 -0700 (PDT) schrieb :

=IF(AND(S95<"",TODAY()<S95),"Investigating PFM",IF(AND(S95<"",TODAY()S95,T95=""),TODAY()-S95&" "&""&"Days Past Due",IF(AND(S95="",T95<""),"Investigation Report Received",IF(AND(S95<"",T95<""),"Investigation Report Received",IF(L95="District Did Not Investigate","PFM Withdrawn",IF(AND(S95="",TODAY()Q95),TODAY()-Q95&" "&""&"Days Past Due",IF(AND(S95="",TODAY()<Q95),"Investigating PFM")))))))

This statement return false when in reality it is true. Why?
IF(L95="District Did Not Investigate","PFM Withdrawn"


you have to put the conditions into the formula in the order of your
priority. The conditions are checked from left to right and if the first
condition is TRUE you get the output for this condition. Following
conditions will not be checked.
Try:
=IF(L95="District Did Not Investigate","PFM Withdrawn",IF(TODAY()<S95,"Investigating PFM",IF(AND(S95<"",TODAY()S95,T95=""),TODAY()-S95&" "&""&"Days Past Due",IF(AND(S95="",T95<""),"Investigation Report Received",IF(AND(S95<"",T95<""),"Investigation Report Received",IF(AND(S95="",TODAY()Q95),TODAY()-Q95&" "&""&"Days Past Due",IF(AND(S95="",TODAY()<Q95),"Investigating PFM")))))))


Regards
Claus B.
--
Vista Ultimate / Windows7
Office 2007 Ultimate / 2010 Professional