Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to calculate Total for different Group from user entries
I got a Question.... Hope someone can help me to solve...
I had do 1 userform that get entries from users. I will get their nam and project that they handle and the hours they spent for the project. For example, I get 5 entries, which a Name Project Hours Dan A 3 Upls B 5 In A 5 Kon B 2 Kasn C 3 Well, after I get this entries, I will sort them base on the projec name. My question is how we gonna to calculate the total hours fo project A, project B and Project C? Since I dunno how many entries wil be made by users(either 2 projects, either 4 projects...and it is no fix) I cannot have total1 = project A, total2= project B..... Is ther any method to calculate the total for each projects -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to calculate Total for different Group from user entries
Assuming project Names starting from B2 and Hours from C2 on sheet Sheet1:
lastr = Worksheets("Sheet1").Range("B65536").End(xlUp).Row ProjectA = Evaluate("=SUMIF(B2:B" & lastr & ",""A"",C2:C" & lastr & ")") ProjectB = Evaluate("=SUMIF(B2:B" & lastr & ",""B"",C2:C" & lastr & ")") MsgBox "Project A: " & ProjectA & vbCrLf & "Project B: " & ProjectB HTH Regards Pascal "unplugs " a écrit dans le message de ... I got a Question.... Hope someone can help me to solve... I had do 1 userform that get entries from users. I will get their name and project that they handle and the hours they spent for the project. For example, I get 5 entries, which a Name Project Hours Dan A 3 Upls B 5 In A 5 Kon B 2 Kasn C 3 Well, after I get this entries, I will sort them base on the project name. My question is how we gonna to calculate the total hours for project A, project B and Project C? Since I dunno how many entries will be made by users(either 2 projects, either 4 projects...and it is not fix) I cannot have total1 = project A, total2= project B..... Is there any method to calculate the total for each projects? --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
conditional formatting to group rows with repeating entries | Excel Discussion (Misc queries) | |||
How do I get the average of entries in a group of columns? | Excel Discussion (Misc queries) | |||
calculate count on 2006 total, 2005 total, etc... | Excel Worksheet Functions | |||
How do I group multiple data entries in sub-groups | Excel Worksheet Functions | |||
Hyperlink for a group of addresses without individual entries? | Excel Discussion (Misc queries) |