There you go use this..
formula--1-->=SUMPRODUCT((TEXT($C$14:$N$14,"mmm")=TEXT(DATE(YEAR(TODAY()),MONTH(TODAY())-1,1),"mmm"))*($B$15:$B$26=$A5),$C$15:$N$26)
Formula--2-->=SUMPRODUCT(($C$14:$N$14<=C1)*($B$15:$B$26=$A5),$C$15:$N$26)
Saurabh...