to make ERRORS "dis-appear", using your example formula:
Formula: copy to clipboard
=IF(ISERROR(SUMPRODUCT(--(MONTH(expences!$B$2:$B$9997)=1),--(YEAR(expences!$B$2:$B$9997)=2012),expences!$G$2:$G$9997)),"",SUMPRODUCT(--(MONTH(expences!$B$2:$B$9997)=1),--(YEAR(expences!$B$2:$B$9997)=2012),expences!$G$2:$G$9997))

(NOTE_ this is for 2003 - users, 2007+, use this :
Formula: copy to clipboard
=IFERROR(SUMPRODUCT(--(MONTH(expences!$B$2:$B$9997)=1),--(YEAR(expences!$B$2:$B$9997)=2012),expences!$G$2:$G$9997),"")