Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default Formula want work

can you tell me why this wont work? I am trying to find how many days in
column H2:H232 are less than 8 if in column D2:D232 the month is January. I
used the formula below as an array formula but it is just counting all of the
days and not the one's less than 8.

{=COUNT(IF(D2:D232="January",H2:H232,"<8"))}
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Formula want work

Maybe

=SUMPRODUCT((D2:D25="January")*(H2:H25<8))

Mike

"drose" wrote:

can you tell me why this wont work? I am trying to find how many days in
column H2:H232 are less than 8 if in column D2:D232 the month is January. I
used the formula below as an array formula but it is just counting all of the
days and not the one's less than 8.

{=COUNT(IF(D2:D232="January",H2:H232,"<8"))}

  #3   Report Post  
Posted to microsoft.public.excel.programming
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Formula want work

This would likely cover it better he
=SUMPRODUCT((TEXT(D2:D25,"mmmm")="January")*(D2:D2 5<"")*(H2:H25<8)*(H2:H25<""))

Your data vis-a-viz count criteria issues could be:
1. You have real dates in col D, not text: January
2. There are blank cells in either/both cols D & H
Any blank cells will be evaluated as a real date in "January" (affects col
D's checks) or as a zero in calcs (affects col H's checks)
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:22,500 Files:370 Subscribers:66
xdemechanik
---
"drose" wrote:
can you tell me why this wont work? I am trying to find how many days in
column H2:H232 are less than 8 if in column D2:D232 the month is January. I
used the formula below as an array formula but it is just counting all of the
days and not the one's less than 8.

{=COUNT(IF(D2:D232="January",H2:H232,"<8"))}

Reply
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
formula to work in a 3-d reference with 2 work books capt c Excel Worksheet Functions 1 April 8th 09 08:04 PM
Sorting the cells of a formula causes the formula to not work Jake Excel Worksheet Functions 3 January 31st 09 04:42 AM
Why does this formula not work? DaveMoore Excel Worksheet Functions 4 February 27th 07 10:02 AM
A search for $ in a formula use to work now it does not work JuneJuly Excel Discussion (Misc queries) 2 November 30th 05 10:13 PM
extract a foldername with a formula-update formula does not work solo_razor[_16_] Excel Programming 2 October 30th 03 03:59 PM


All times are GMT +1. The time now is 03:26 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"