A
azu_daioh
I'm having trouble with this DCOUNT, please help!!
The Forms.[FOReport] is filtered by 4 category:
EntryDate
DateCleared
FONum
EEName
But on the same form, I would like a total of the following:
NewReferrals = which is the total of all records with EntryDate
11/01/07 - 11/30/07
OldReferrals = which is the total of all records with DateCleared
11/01/07 - 11/30/07 And EntryDate before 11/01/07
I have this DCOUNT:
Dim xBDate = Me.fltrBDATE --> which is 11/01/07
Dim xEDate = Me.fltrEDATE --> which is 11/30/07
xTotalOldRef= DCount("[EntryDate]", "[ID Flag]", Me.Filter & _
" And DateCleared > #" & xBDate - 1 & _
"# And DateCleared < #" & xEDate + 1 & "# ")
Me.OldReferrals = xTotalOldRef
The above DCount only gives me the total of old referrals with date
cleared 11/01/07-11/30/07 BUT NOT with EntryDate before 11/01/07
I tried inserting AND EntryDate < #" & xBDate & "# but it didnt
work.
Can someone solve this for me please . I would greatly appreciate it.
Thank you,
Sharon
The Forms.[FOReport] is filtered by 4 category:
EntryDate
DateCleared
FONum
EEName
But on the same form, I would like a total of the following:
NewReferrals = which is the total of all records with EntryDate
11/01/07 - 11/30/07
OldReferrals = which is the total of all records with DateCleared
11/01/07 - 11/30/07 And EntryDate before 11/01/07
I have this DCOUNT:
Dim xBDate = Me.fltrBDATE --> which is 11/01/07
Dim xEDate = Me.fltrEDATE --> which is 11/30/07
xTotalOldRef= DCount("[EntryDate]", "[ID Flag]", Me.Filter & _
" And DateCleared > #" & xBDate - 1 & _
"# And DateCleared < #" & xEDate + 1 & "# ")
Me.OldReferrals = xTotalOldRef
The above DCount only gives me the total of old referrals with date
cleared 11/01/07-11/30/07 BUT NOT with EntryDate before 11/01/07
I tried inserting AND EntryDate < #" & xBDate & "# but it didnt
work.
Can someone solve this for me please . I would greatly appreciate it.
Thank you,
Sharon