![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: May 2002
Location: Baton Rouge
Posts: 39
|
TsTom has provided EXCELLENT assistance in making it easier to find all the data in the spreadsheet. I am looking for some assistance still in creating a formula that would calculate all calls that came in after 5:30 PM but before 8:30 AM (non-day specific)
The date column is B:9 down and the time column is C:9 down. I would need it to disregard blanks. Any assistance would be greatly appreciated for this last one. The following the current formulas in place: Sunday Calls: =SUMPRODUCT((WEEKDAY(B5:B1066)=1)+0) Reservation Total: =COUNTIF(E9:E1066,"R") Message Total: =COUNTIF(E9:E1066,"M") Exceptions Total: =COUNTIF(E9:E202,"X")+COUNTIF(E9:E202,"I")+COUNTIF(E9:E202,"C")+COUNTIF(E9:E202,"E")+COUNTIF(E9:E202,"V") Total Number of Calls: =COUNTIF(E9:E1066,"X")+COUNTIF(E9:E1066,"I")+COUNTIF(E9:E1066,"C")+COUNTIF(E9:E1066,"E")+COUNTIF(E9:E1066,"V")+COUNTIF(E9:E1066,"R")+COUNTIF(E9:E1066,"M") [ This Message was edited by: snedman on 2002-05-06 11:21 ] |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Denver, CO
Posts: 1,744
|
=COUNTIF(C9:C65536,"<"&"8:30"+0)+COUNTIF(C9:C65536,">"&"17:30"+0)
|
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Mar 2002
Location: Cincinnati, Ohio, USA
Posts: 6,824
|
Make sure you delete this line of code in the macro I sent you.
The formula will be overwritten if you do not. DELETE:
Tom |
|
|
|
|
|
#4 |
|
New Member
Join Date: May 2002
Location: Baton Rouge
Posts: 39
|
SHA ZAM it worked. THANK YOU THANK YOU.
Snedman |
|
|
|
|
|
#5 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Michigan USA
Posts: 11,452
|
Use the following array formula
{=SUM(IF(C9:C100>=C7,IF(C9:C100<=D7,1,0),0))} where C7 houses 8:30 AM and D7 houses 5:30 PM _________________ Yogi Anand Edit: Deleted reference to inactive web site from signature line [ This Message was edited by: Yogi Anand on 2003-01-19 18:36 ] |
|
|
|
|
|
#6 |
|
MrExcel MVP
Join Date: Feb 2002
Location: The Hague
Posts: 50,317
|
On 2002-05-06 10:45, snedman wrote: TsTom has provided EXCELLENT assistance in making it easier to find all the data in the spreadsheet. I am looking for some assistance still in creating a formula that would calculate all calls that came in after 5:30 PM but before 8:30 AM (non-day specific) The date column is B:9 down and the time column is C:9 down. I would need it to disregard blanks. Any assistance would be greatly appreciated for this last one. =COUNT(C9:C1066)-SUMPRODUCT((C9:C1066>F1)*(C9:C1066 where F1 houses 8:30 (that is: 8:30:00 AM) and F2 17:30 (that is: 5:30:00 PM). It shouldn't be too difficult to do the same with COUNTIF (which is less expensive). Exceptions Total: =COUNTIF(E9:E202,"X")+COUNTIF(E9:E202,"I")+COUNTIF(E9:E202,"C")+COUNTIF(E9:E202,"E")+COUNTIF(E9:E202,"V") Given the long chain of COUNTIFs, I don't see any harm in using instead: =SUMPRODUCT((E9:E202={"X","I","C","E","V"})+0) Total Number of Calls: =COUNTIF(E9:E1066,"X")+COUNTIF(E9:E1066,"I")+COUNTIF(E9:E1066,"C")+COUNTIF(E9:E1066,"E")+COUNTIF(E9:E1066,"V")+COUNTIF(E9:E1066,"R")+COUNTIF(E9:E1066,"M") Again by the above reasoning, I'd suggest: =SUMPRODUCT((E9:E1066={"X","I","C","E","V","R","M"})+0) Aladin |
|
|
|
|
|
#7 |
|
New Member
Join Date: May 2002
Location: Baton Rouge
Posts: 39
|
Done TsTOM thank you for that followup.
Thank you very much also IML. You guys are life savers. |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|