Need Paramater Translation Help

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can someone tell me why this doesn't work when passing this paramater to a form!

Like "*" Or Is Null

If I open up the form-recordsource and place the same line in the criteria box it works fine. Is there different formatting you need if you put Like [Forms]![SearchForm]![txtCustomer] in the criteria box? I would think that would translate to Like "*" Or Is Null

Any input?

Thanks
 
brian said:
Can someone tell me why this doesn't work when passing this paramater
to a form!

Like "*" Or Is Null

If I open up the form-recordsource and place the same line in the
criteria box it works fine. Is there different formatting you need
if you put Like [Forms]![SearchForm]![txtCustomer] in the criteria
box? I would think that would translate to Like "*" Or Is Null

Any input?

Please show the code wherein you are passing this parameter. If you are
talking about opening the form using DoCmd.OpenForm and specifying this
as part of the where-condition argument, it needs to look something like
this:

DoCmd.OpenForm "FormName", _
WhereCondition:="Customer Like ""*"" Or Customer Is Null"
 
When you open the form's record source, it is a query.

The query grid has an expression service which will evaluate what you enter and
attempt to force it into useable SQL. When you pass a parameter to a form, the
expression service is not be available or cannot interpret what you are
attempting to pass.

Can you post the code you are using?
 
Back
Top