Very strange error

S

superkopite

Hiya guys and gals

I have the following piece of code;

=IF((E$2>=$B6)*(E$2<=$D6),1,)

Cells E2:AZ2 contain time (00:30,01:30,02:00 and so on)

So the code will work as follows, if E2 is greater than or equal to B6,
an employees start time, but less than or equal to D6, an employees
finish time, then current cell =1.

Now this works fine from 03:00 onwards, but before this time it seems
to take away thirty mins. For example if an employees start time is
02:00 the first "1" will be in the 02:30 box! Like i said after 03:00
the program works perfectly i just cannot seem to understand what the
problem is.

Any help will be greatly appriciated.

Cheers

James
 
R

Roger Govier

Hi

Try re-typing the value 2:00 in cell H2
I can re-create your problem if I type 1:59:59.59 in H2. It displays as
2:00 but obviously it's internal value is less than 2:00 hence the test
fails.

--
Regards

Roger Govier


"superkopite" <[email protected]>
wrote in message
news:[email protected]...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top