Counting client service days by month - Microsoft Community


it 7 day week. in excel i have list of hundreds of clients added daily. each client receives short term care for up 6 weeks. rows of data start row 7. first client have start date in m7, end date in o7 , if have not ended yet o7 blank. in w7 ah7 want record number of days client received service each calendar month. w1 ah6 empty.

 

i defeated. how do please?

enter below formula in cell w7 & copy down , right:

=if(or(min($o7,today())<=$m7,month(1&w$6)<month($m7)),0,if(min($o7,today())>eomonth($m7,month(1&w$6)-month($m7)-1),min(min($o7,today())-1,eomonth($m7,month(1&w$6)-month($m7)))-max($m7,eomonth($m7,month(1&w$6)-month($m7)-1)+1)+1,0))

formula returns 0 if end date equal or less start date. if end date blank or end date later today's date (current date), current date taken calculation.

note: additional check can entered in case there possibility of start date being blank.

regards,

amit tandon

www.globaliconnect.com



Office / Excel / Windows 10 / Office 2013



Comments

Popular posts from this blog

Getting ErrorCode: 120018 when trying to access Microsoft account - Microsoft Community

The message was sent to a distribution list ‎(DL)‎ - Microsoft Community

Activation Error 0x8004FE93 - Microsoft Community