Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Bob,
I think this is the right track I need to take but I have found the formula is even more complex and can not get it to work. Hopefully you can help. It is going to have to be a nested If Then Statement. The first thing I need to do is see If B2=B1 If it is false then put 0. If it is true then need to test If Hour(G2)<4 If this is True then need this formula ROUND(MOD(G2-H1,1)*1440,0) else use this formula ROUND(MOD(G2-MAX(H1,(VLOOKUP(A2,RRInfo,5,FALSE))),1)*1440,0) Do you know how to put this together into one big formula?? "Bob Phillips" wrote: =IF(HOUR(G2)<4,formula1,formula2) -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Scott" wrote in message ... I am creating a new column for an Excel program but this column needs to use two different formulas based on a Start time in column G. If the Start time is before midnight then I use one fomula and if the start time is after midnight but before 4 a.m. then I use a different formula. The formulas work perfect but I can't seem to write the initial condition correctly so that it knows which formula to use. Essentially, how could I write an If Then statement that says if the scan time in cell ( #, G ) is 24:00 and < 04:00 then Calculation # 1 Else Calculation # 2 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA code needed | New Users to Excel | |||
Help with code needed | Excel Programming | |||
Code Help Needed | Excel Programming | |||
Code Help Needed | Excel Programming | |||
Code Needed | Excel Programming |