Quote:
Originally Posted by GeorgeCC
Hi there,
I have the following prompt in my query:
[Enter City to visit, New York Or Boston:]
So the user selects the city they are after.
Is there a way to adjust this prompt so if the user leaves it blank it will populate the query/report with both cities, i.e Boston and New York?
thanks
George
|
Hi
You could try something like this
Code:
IIf(IsNull([Enter City to visit, New York Or Boston:]),"New York",[Enter City to visit, New York Or Boston:]) Or IIf(IsNull([Enter City to visit, New York Or Boston:]),"Boston",[Enter City to visit, New York Or Boston:])
It is not clear if there are more that the two Cities available in the DB, if so, then this should do what you indicated.
If there are more than two, and you want them all retuning if the request is left blank, then use this
Code:
Like IIf(IsNull([Enter City to visit, New York Or Boston:]),"*",[Enter City to visit, New York Or Boston:]) Or IIf(IsNull([Enter City to visit, New York Or Boston:]),"*",[Enter City to visit, New York Or Boston:])
MTB