hockeyfan21
Registered User.
- Local time
- Today, 09:03
- Joined
- Aug 31, 2011
- Messages
- 38
Hi,
I have 3 combo boxes on a form that I am filtering another form/report based on a table in VBA using stLinkCriteria
This is all working fine but I also need to put a hard filter for 2 other fields in the same table where [Approved] = 0 and [Denied]=0. My Debug.Print shows
[Category]= '2000 - RUNNING' OR [ProdtSubCatLongDesc]='2000 - RUNNING' AND [Approved] = FALSE
but it isn't actually filtering out the [Approved] entries.
VBA (1st combo box only)
any ideas on what I'm doing wrong? I've also used '0' instead of FALSE but get the same results.
Thank you!!
Toni
I have 3 combo boxes on a form that I am filtering another form/report based on a table in VBA using stLinkCriteria
This is all working fine but I also need to put a hard filter for 2 other fields in the same table where [Approved] = 0 and [Denied]=0. My Debug.Print shows
[Category]= '2000 - RUNNING' OR [ProdtSubCatLongDesc]='2000 - RUNNING' AND [Approved] = FALSE
but it isn't actually filtering out the [Approved] entries.
VBA (1st combo box only)
Code:
If IsNull(cboDiv) And IsNull(cboGender) Then
stLinkCriteria = "[Category]= '" & Me.cboByCategory & "' OR [ProdtSubCatLongDesc]='" & Me.cboByCategory & "'"
stLinkCriteria2 = "[Approved] = FALSE "
stLinkCriteria3 = stLinkCriteria & " AND " & stLinkCriteria2
Debug.Print stLinkCriteria3
any ideas on what I'm doing wrong? I've also used '0' instead of FALSE but get the same results.
Thank you!!
Toni