LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 67
Default if statement with functions

This is the set-up (military time):

12:00 13:36 96 <- this calculation is the amount of minutes that the time
frame creates this is the calculation to get the amount of minutes:
=MINUTE(B6)-MINUTE(C6)*(-1)+((HOUR(B6)-HOUR(C6))*(-1))*60 (Next to this cell
will be the amount of units that the minutes equals see below for ex.)

(will start line with)- client # 12:00 13:36 96 7 <- 96
minutes = 7 units

so on another sheet there's a table that has ranges the first number is the
number of units the range is the amount of minutes that satisfy that unit
amount ex:
1 5 6 7 8 9 10 11 12 13 14 15 <- range 5-15 = 1 unit
2 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 <- range 16-30 = 2 units etc

this table goes all the way to 75 units so this table is large.

So what I am driving at is this:
If the # of minutes is 4, then look up the minute amount in the table and
return the unit, else the number of minutes is less than 4 return 0)
Also at the end of the entries I want to tally up the amount of units that
each client # has because usually there are more than one entry per client.
Ex.

1000 13:00 13:04 4 0
1000 14:05 14:10 5 0 1 <- 1 unit because of two
entries...

Any suggestions or ideas this is a big one. I have been toying with it but
need some sort of guidance. Don't know VB or Excel to this extent. Thanks for
any suggestions or help that is offered it is greatly appreciated.






"Fredrik Wahlgren" wrote:


"Beth" wrote in message
...
how can I get and if statement to read if(a value in cell d6 4, then
look-up a value in this table and return the amount hat value equals, else
entry is not greater than 4 and needs to be added to some sort of counter
that would keep track of instances from that id) any ideas? Thanks Beth


I think you need to submit a complete example. What is "this table" and
"instances from that id" ?
/Fredrik



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
IF statement inside a SUMIF statement.... or alternative method Sungibungi Excel Worksheet Functions 3 December 4th 09 06:22 PM
Reconcile Bank statement & Credit card statement & accounting data Bklynhyc Excel Worksheet Functions 0 October 7th 09 09:07 PM
How to convert cell formula functions to code functions Adnan Excel Discussion (Misc queries) 1 October 1st 08 08:30 PM
efficiency: database functions vs. math functions vs. array formula nickname Excel Discussion (Misc queries) 2 July 14th 06 04:26 AM


All times are GMT +1. The time now is 06:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"