I am to write a formula that will move or update as the date of an item changes.

For example, if you have a payment that is do on 1/3/2017 for $100.00 in cells A1 & B1 respectively, I am using the formula =IF(AND(A1<=1/01/2017,A1>=1/7/2017),B1,0) but no values are calculating.
I've also tried =IF(AND(A1<=DATE(2017,1,1),A1>=DATE(2017,1,31)),B1,0) and again it doesn't give me the right calculation.

Thanks in advance!