L
Lars Munch
Hi
When I have a form containing a sub form, the data of the
main form and the sub form resp. is selected by two
queries. I have one filter for the main form and another
filter for the sub form. The buttons to edit and apply
the filter for the sub form are located within the sub
form, and the buttons to edit and apply the filter for
the main form are located outside the sub form. When I
press the button to apply the filter for the sub form,
Access prompts me for the values in the query defining
the data of the sub form, as if Access at this point can
only read the query for the main form. If I right-click
any of the buttons and select "disregard filter", Access
disregards the filters both for the main form and the sub
form.
In order to use the same filters for reports, I have
saved them as queries. Therefore it has been necessary
to modify the VB code for the buttons compared to the
code generated automatically by the button wizard. My
code is functioning OK for forms without sub forms and
for the main form as well, but not for the sub form. It
is also functioning for reports without sub reports.
Isn't Access able to handle filters in sub forms properly?
Regards
Lars
When I have a form containing a sub form, the data of the
main form and the sub form resp. is selected by two
queries. I have one filter for the main form and another
filter for the sub form. The buttons to edit and apply
the filter for the sub form are located within the sub
form, and the buttons to edit and apply the filter for
the main form are located outside the sub form. When I
press the button to apply the filter for the sub form,
Access prompts me for the values in the query defining
the data of the sub form, as if Access at this point can
only read the query for the main form. If I right-click
any of the buttons and select "disregard filter", Access
disregards the filters both for the main form and the sub
form.
In order to use the same filters for reports, I have
saved them as queries. Therefore it has been necessary
to modify the VB code for the buttons compared to the
code generated automatically by the button wizard. My
code is functioning OK for forms without sub forms and
for the main form as well, but not for the sub form. It
is also functioning for reports without sub reports.
Isn't Access able to handle filters in sub forms properly?
Regards
Lars