# Formula to count days and reset count

1. ## Formula to count days and reset count

Hi! I need some help with formula to count days of different Users ID like the example I have on column D and then reset the count if I have a value grater than zero on column C
Day count.xlsx
Thanks.

2. ## Re: Formula to count days and reset count

What is the criteria to add days to the count?

3. ## Re: Formula to count days and reset count

Hi! this is what I have so far, I have this formula =IF(B2=\$B1:B\$2,DATEDIF(\$A\$2,A2,"D"),0) on column E but is only counting on the first User ID 114662 but not for 111111, but is still I don't know how to reset the count if I have a value grater than zero on column C and start the count from where the reset count is.

Thanks.

Bump

Thanks.

5. ## Re: Formula to count days and reset count

The function above has tree arguments: the date range, User ID range and reset count range (in the specific row that you start the count). So paste the code into one module and the formula "=SpecialCount(A3,B3,C3)" in cell "E3".

``Please Login or Register  to view this content.``

6. ## Re: Formula to count days and reset count

Hi! I pasted the code to a module and pasted the formula on E3 an E3 is showing #NAME?. I am doing something wrong.

2015-05-26 10-27-32_Day count (1).png

7. ## Re: Formula to count days and reset count

Lets try the attached file.

Thanks

8. ## Re: Formula to count days and reset count

Hi! Victor this is almost what i need but column E is not working right on some rows does not count the days or when there a one does not reset. Can you help me out with this?

Thanks!

Day count.xlsm

9. ## Re: Formula to count days and reset count

Hello,

Ok, Error will occur when value should be "0". That is why i put one "IFERROR" formula.

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

#### 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