sub form filtering with cbo

R

Robert Sharp

I have created a cbo box on a main form to filter records
in a subform. Does anyone know how I can show all records
again after the filter has been applied? I am using MS
Access 2002.
 
A

Arvin Meyer

Robert Sharp said:
I have created a cbo box on a main form to filter records
in a subform. Does anyone know how I can show all records
again after the filter has been applied? I am using MS
Access 2002.

Several ways. Perhaps the easiest is a button with a line of code something
like:

DoCmd GoToControl "Name of Subform"
DoCmd.ShowAllRecords
 
R

Robert Sharp

Hi and Thanks for your help BUT the subform still doesn't
show all records again after the filter has been applied.
I have created a blank form with no fields and placed a
subform on it based on my mailing address query in
datasheet view (a total of 20 records), I then placed the
cbo box named cboLookup on the blank main form and linked
it to the subform child [CompanyName] and master
(cboLookup) links, this works fine to filter the subform
by company name but I can't show my original 20 records
back in datasheet view after the filter has been applied
to do a mass mailout.
I would appreciate any help on this as I am going nuts.

Thanking you in advance
Robert
 
A

Arvin Meyer

Does the combo have a filter too? If so, you might need to set its RowSource
to get the entire set of records, or more likely, just set its value to an
empty string. If the subform is requerying the same filter, you get the same
results.
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads:
http://www.datastrat.com
http://www.mvps.org/access

Robert Sharp said:
Hi and Thanks for your help BUT the subform still doesn't
show all records again after the filter has been applied.
I have created a blank form with no fields and placed a
subform on it based on my mailing address query in
datasheet view (a total of 20 records), I then placed the
cbo box named cboLookup on the blank main form and linked
it to the subform child [CompanyName] and master
(cboLookup) links, this works fine to filter the subform
by company name but I can't show my original 20 records
back in datasheet view after the filter has been applied
to do a mass mailout.
I would appreciate any help on this as I am going nuts.

Thanking you in advance
Robert
-----Original Message-----


Several ways. Perhaps the easiest is a button with a line of code something
like:

DoCmd GoToControl "Name of Subform"
DoCmd.ShowAllRecords


.
 
R

Robert Sharp

I don't know what I'm doing wrong, the cbo was based on
my company table (CompanyID and CompanyName) and the
subform was based on a query(the company mailing
addresses), as soon as I deleted the link from the cbo to
the subform I got all records showing again in datasheet
view. What am I doing wrong??
-----Original Message-----
Does the combo have a filter too? If so, you might need to set its RowSource
to get the entire set of records, or more likely, just set its value to an
empty string. If the subform is requerying the same filter, you get the same
results.
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads:
http://www.datastrat.com
http://www.mvps.org/access

Robert Sharp said:
Hi and Thanks for your help BUT the subform still doesn't
show all records again after the filter has been applied.
I have created a blank form with no fields and placed a
subform on it based on my mailing address query in
datasheet view (a total of 20 records), I then placed the
cbo box named cboLookup on the blank main form and linked
it to the subform child [CompanyName] and master
(cboLookup) links, this works fine to filter the subform
by company name but I can't show my original 20 records
back in datasheet view after the filter has been applied
to do a mass mailout.
I would appreciate any help on this as I am going nuts.

Thanking you in advance
Robert
-----Original Message-----
I have created a cbo box on a main form to filter records
in a subform. Does anyone know how I can show all records
again after the filter has been applied? I am using MS
Access 2002.

Several ways. Perhaps the easiest is a button with a line of code something
like:

DoCmd GoToControl "Name of Subform"
DoCmd.ShowAllRecords


.


.
 

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