I'm using the following to obtain a date range of records
Sum(IIf([ACDateRec] Between [Forms]![frmDiaryMain]![UBDATESTART] And [Forms]![frmDiaryMain]![UBDATEEND],[GROSSTOTAL],0))
However the search fails to find all records between dates.
I wish to change the above so rather than use Between I use
Sum(IIf([ACDateRec] >=[Forms]![frmDiaryMain]![UBDATESTART] And <[Forms]![frmDiaryMain]![UBDATEEND],[GROSSTOTAL],0))
Problem Access is happy with >= but produces a syntax error message when I enter the < after the "AND"
Help would be nice.
S.Eke (aka Half way up a wall trying to get it to work)
Sum(IIf([ACDateRec] Between [Forms]![frmDiaryMain]![UBDATESTART] And [Forms]![frmDiaryMain]![UBDATEEND],[GROSSTOTAL],0))
However the search fails to find all records between dates.
I wish to change the above so rather than use Between I use
Sum(IIf([ACDateRec] >=[Forms]![frmDiaryMain]![UBDATESTART] And <[Forms]![frmDiaryMain]![UBDATEEND],[GROSSTOTAL],0))
Problem Access is happy with >= but produces a syntax error message when I enter the < after the "AND"
Help would be nice.
S.Eke (aka Half way up a wall trying to get it to work)