Wildcards Access 2007

David Eagar

Registered User.
Local time
Tomorrow, 04:45
Joined
Jul 2, 2007
Messages
922
I have tried several solutions propsed in searches of the forum, but can't get any of them to work.

I have a form with a text box and combo box, with subform derived from a query. If I enter value in textbox and select from combo box, all is right with the world, I am after all records if I leave the combobox empty

AfterUpdate of text box if [combobox]="" then [combobox]="*" also tried
AfterUpdate of text box if [combobox]=Null then [combobox]="*"

What's driving me nuts is that if I manually run the query and enter a textbox value and a * for the combo box, it works as i expected

Which bit am I missing here?

All contributions wlecome
 
An empty combo is not an empty string.
The = operator cannot be used with Null

Try:
If IsNull([combobox]) Then: [combobox] = "*"
 
Thanks kindly, works a treat - muchos gracias
 

Users who are viewing this thread

Back
Top Bottom