+ Reply to Thread
Results 1 to 3 of 3

Month() counts empty cells?

  1. #1
    Forum Contributor
    Join Date
    03-24-2009
    Location
    Vietnam
    MS-Off Ver
    Excel 2010
    Posts
    382

    Month() counts empty cells?

    Hi,

    it seems that suddenly (?) my month() formula is returning empty cells as default "1" (= January), screwing up my statistics. I have a raw data list with dates in the DD/MM/YYYY format and need to count the entries per month, therefore am using
    Please Login or Register  to view this content.
    to do so. But since today it seems to somehow add me all blank cells as well, which it didnt before.

    Whats going on? Any alternative?

    Thanks,
    A2k

  2. #2
    Forum Expert
    Join Date
    09-27-2011
    Location
    Poland
    MS-Off Ver
    Excel 2007
    Posts
    1,312

    Re: Month() counts empty cells?

    Hi use this
    =SUMPRODUCT((IF(B2:B2000<>"",MONTH(Data!B2:B2000)=1,0)*1))
    confirmed with CTRL+SHIFT+ENTER
    Regards

    tom1977

    If You are satisfied with my solution click the small star icon on the left to say thanks.

  3. #3
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Month() counts empty cells?

    empty cells count as 0 which is 0 Jan 1900 in excel world
    =SUMPRODUCT((Data!B2:B2000<>"")*(MONTH(Data!B2:B2000)=1))
    will fix it (no array entry)
    Josie

    if at first you don't succeed try doing it the way your wife told you to

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1