filter syntax

G

Guest

Given that

Me.Form(strFoundItemsForm).Name

returns the correct result, and that

strSQL = "Item = '1'"

can anybody see why this statement

Me.Form(strFoundItemsForm).Filter = strSQL

should cause "Run-time error '438': Object doesn't support this property or
method"?

Thanks!
 
G

Guest

Sorry, I might not have given enough info. 'Me.Form(strFoundItemsForm)' is
obviously a subform. It is set to display in 'datasheet view'. There is a
query behind it; is that my problem?
 
S

strive4peace

Hi Allen,

try this:

Me.Form(strFoundItemsForm).Form.Filter = strSQL

Me.Form(strFoundItemsForm) is the subform control -- its height, width,
SourceObject, etc

Me.Form(strFoundItemsForm).Form is the form inside the subform control
-- and that is where your records are...

Warm Regards,
Crystal
*
:) have an awesome day :)
*
MVP Access
Remote programming and Training
strive4peace2006 at yahoo.com
*
 
G

Guest

Thankyou very much, Crystal.

I was starting tho think i would have to join some secret society before the
arcane syntax of forms would be fully revealed to me.
 
S

strive4peace

LOL!

you're welcome, Allen ;) happy to help

Warm Regards,
Crystal
*
:) have an awesome day :)
*
MVP Access
Remote Programming and Training
strive4peace2006 at yahoo.com
*
 

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

Top