have another look at your code

vb Code:
  1. If dtpDate.Value >= dateThirty And dtpDate.Value <= dateThirty Then

that'll never be executed. it can't be >= and <= at the same time unless its =