Filtering in a form

S

SMiller

I'm opening a form and setting the filter as follows:

DoCmd.OpenForm "SalesbyProductDetailedForm", , ,
"[SalesbyProductDetailedForm]![ProductCode] = '" & Me!
[ProductCode] & "'"

However, this command
gives me a space infront of the Me![ProductCode] value,
thus creating the filter to fail.

How do I get rid of it

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Opening a form and setting filter 3
form to form 1
Referring to control on subform 3
Blank Fields in Report 2
error 3001 1
Wait fr Form to Close 10
Simple Form 2
Dlookup condition result 4

Top