By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,983 Members | 2,082 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,983 IT Pros & Developers. It's quick & easy.

Syntax for correctly setting filter property in property sheet for form

P: n/a
MLH
I have an A97 form opened in design view:
frmAuthEntityEditingForm bound to tblAuth

In the open property sheet on the Data tab,
the 2nd item down in the list is the filter property.
In it, I have typed the following:
AuthID=GetCurrentAuthEntity()

But still, all the records in tblAuth display in the
form rather than the SINGLE record that I want.
Of course I could make the form's control source
a query instead of a table and I could limit the query
dynaset to a single record with the criteria. But I
thought I would try the filter property this time. It
doesn't work with the syntax I'm using. That's
why I've never done it. The HELP is not well
documented and what appears obvious to me
is definitely not working.
Mar 16 '07 #1
Share this Question
Share on Google+
1 Reply


P: n/a
You need to turn the FilterOn so it is applied:

Me.Filter = "AuthID = " & GetCurrentAuthEntity()
Me.FilterOn = True

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"MLH" <CR**@NorthState.netwrote in message
news:18********************************@4ax.com...
>I have an A97 form opened in design view:
frmAuthEntityEditingForm bound to tblAuth

In the open property sheet on the Data tab,
the 2nd item down in the list is the filter property.
In it, I have typed the following:
AuthID=GetCurrentAuthEntity()

But still, all the records in tblAuth display in the
form rather than the SINGLE record that I want.
Of course I could make the form's control source
a query instead of a table and I could limit the query
dynaset to a single record with the criteria. But I
thought I would try the filter property this time. It
doesn't work with the syntax I'm using. That's
why I've never done it. The HELP is not well
documented and what appears obvious to me
is definitely not working.
Mar 16 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.