Thread: IF question
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Max Max is offline
external usenet poster
 
Posts: 9,221
Default IF question

One try:
=IF(F5="COS",IF(M5<B5,"Late ","Early ")&TEXT(ABS(M5-B5),"hh:mm:ss"),
IF(F5="ACE",IF(L5<B5,"Late ","Early ")&TEXT(ABS(L5-B5),"hh:mm:ss"),""))
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:22,500 Files:370 Subscribers:66
xdemechanik
---
"puiuluipui" wrote:
Hi, i have this code:
=IF(M5<B5,"Late ","Early ")&TEXT(ABS(M5-B5),"hh:mm:ss")

I need it a little more complex.

I need the code to look in F5 and if the code find "COS" to know that the
reference is in M5. If the code find (ACE) to know that the reference in in
L5. After that, the code to look in B5. If the time is smaller than M5 or L5,
the result to be "early". If the time is bigger, than the result to display
"late".
Can this be done?
Thanks in advance.