guamlet
Board Regular
- Joined
- Dec 29, 2002
- Messages
- 145
I'm writing a query that's being run from a form. In the form, i have a check box. If the check box is checked, i would like to display any of the values that are not blank. If the check box is empty, i would like to display all values, blank and non-blank. The issue I think i'm having may be centered around the fact that the field in quesiton within the query contains hyperlinks. I have only been able to populate the query by using the name of the field [RNALoc] as either the true or false criteria for the iif statement i'm writing. Below is the IIF statement that i'm envisioning)
IIF([Forms]![Query Form]![chkItem]=-1, Is not null, All values)
So if I write the statement as
IIF([Forms]![Query Form]![chkItem]=-1,[RNALoc],[RNALoc])
I can get it to show everything that is not a null value
If I change the null values to 0, which then has the hyperlink address "http://0", then I can see everything with [RNALoc]. However, if I write
IIF([Forms]![Query Form]![chkItem]=-1, <>"http://0", [RNALoc])
or if i write
IIF([Forms]![Query Form]![chkItem]=-1 <>0, [RNALoc])
I retuen no values when the check box is checked. and I can still return all values when the check box is unchecked.
Any suggestions?
IIF([Forms]![Query Form]![chkItem]=-1, Is not null, All values)
So if I write the statement as
IIF([Forms]![Query Form]![chkItem]=-1,[RNALoc],[RNALoc])
I can get it to show everything that is not a null value
If I change the null values to 0, which then has the hyperlink address "http://0", then I can see everything with [RNALoc]. However, if I write
IIF([Forms]![Query Form]![chkItem]=-1, <>"http://0", [RNALoc])
or if i write
IIF([Forms]![Query Form]![chkItem]=-1 <>0, [RNALoc])
I retuen no values when the check box is checked. and I can still return all values when the check box is unchecked.
Any suggestions?