- Subject: Outlook Restrict on SentOn (using Between)
- Author: McKilty
- Date: 28 Sep 2009
- References:
Hello all,
I am trying to figure to the proper syntax for using Restrict on the
SentOn field. I need to restrict between two dates, but so far
nothing is filtering to the exact date range I'm looking for. I have
tried:
Set mItemCollection = mItemCollection.Restrict("[SentOn] > '" &
dteStart & "' AND [SentOn] < '" & dteEnd & "'")
Set mItemCollection = mItemCollection.Restrict("[SentOn] = '" &
dteStart & "'")
Set mItemCollection = mItemCollection.Restrict("[SentOn] Between '" &
dteStart & "' AND '" & dteEnd & "'")
Thanks for the help.