I have a table or Query in my report with these fields:
Name, Country, Ship
I create 2 Variables PickCountry and PickShip to show two comboboxes for Country and Ship.
The comboboxes show all the countries and all the ships in my table.
The filter-expressions look like this: (MyTable.Country == PickCountry)
So far so good… I can choose a Country and a Ship and the result in the report is Ok.
But now I only want to choose a Country and not a specific Ship.
Or.. a Ship and not a specific Country.
I could create 2 boolean Variables to show 2 Checkboxes: AllCountries and AllShips.
In my filter-expressions I would write something like this
(MyTable.Country == PickC ountry || AllCountries)
But this is not very userfriendly and what if I had 4 comboboxes. Then I also need 4 checkboxes.
So the question is:
Is it possible to add an Item “All countries” in my country-combobox. And what should I write in my filter-expression:
IIf PickCounty != “All countries” then MyTable.Country == PickCounty….??
Or… what with a checkbox as a part of a combox to enable and disable the combobox.
Variables and Expressions
-
- Posts: 46
- Joined: Thu Jan 10, 2013 11:40 am
Re: Variables and Expressions
Hello.
One way is to add a record in your data source.
You could try to create a Form and put there Comboboxs and add item there.
Thank you.
One way is to add a record in your data source.
You could try to create a Form and put there Comboboxs and add item there.
Thank you.