View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dave Naples Dave Naples is offline
external usenet poster
 
Posts: 1
Default If statement with time values

Hello:

I'd like to implement an if statement to return a value for whether the
time-of-day from a specific column is during the "day" or "night". I have
one column (K) with time in the hhmm format. I've attempted the following,
but it only gives me "night" as the result for all cases so something is not
working correctly.

=IF(AND(K3<TIME(19,0,0),K3TIME(6,59,0)),"DAY","NI GHT")

Could it have to do with my time format for column K? Any help would be
greatly appreciated