Store Common Filters in table ? ? (1 Viewer)

Cameroncha

Registered User.
Local time
Today, 09:22
Joined
Jul 1, 2002
Messages
58
I am new to Access... just updated to SQL server and the company is really on me to get this database in shape.

Anyhow, enough crying... here is what i am trying to do.

I have a common table called 'main' that i tend to filter a lot manually to manipulate data.

What i would like is a popup before the form is loaded, allowing me to choose a filter from a 'Filters' table (perhaps by an id field)

Any suggestions, places to look. I am not a real programmer yet but i am starting to see the light.

thanks a bunch!
 

dcx693

Registered User.
Local time
Today, 04:22
Joined
Apr 30, 2003
Messages
3,265
Why not store the filters as Access queries and apply them to the form as required? (I'm using Access 2002 right now, so I don't know if these capabilities are available for previous versions.) When you have a form open, you can go to the Records menu, Filter, Advanced Filter/Sort... The view should look familiar, it's the QBE grid. When you're done making your selections, click on the Save As Query button. You should then be able to load the queries as filters for your form.
 

Matthew Snook

NW Salmon Database
Local time
Today, 09:22
Joined
Apr 19, 2001
Messages
133
You should be able to do as you've described. A table could hold query text in one column and a memorable name for it in another. The combo box with this table as a data source would allow the user to choose filters by name, then use the "After Update" event to write the text to the filter property of the form and reapply the filter.

With little more sophisticated text handling you could even combine multiple filters or clear all filters and start over.

Matt
 

Cameroncha

Registered User.
Local time
Today, 09:22
Joined
Jul 1, 2002
Messages
58
to write the text to the filter property of the form and reapply the filter.

this is the part that i am not clear quite how to do. I start looking at the VB code and get way overwhelmed because the are so many types.

all this me.this.that stuff i just dont understand yet.

I am reading VB.NET programming for beginners, so some stuff is beginning to become 'friendlier' looking. Thanks.
 

Users who are viewing this thread

Top Bottom