Create report from filtered recordset on form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form which allows users to filter records based on certain criteria
(via the built-in filter functions).

I would like to have a button which will open a datasheet view of the
filtered recordset so that the user can export it to excel, word, etc.

I can't just use the built-in Datasheet view because there are subforms on
the form which contain data that I would need to have available on the
datasheet. I think what I really need is the ability to save the current
recordset as a query so that I can display the resulting records, but am
unsure as to how to do it.

Can any of you help me out?

Any help would be greatly appreciated!
 
Hi JRB.

JRB said:
I have a form which allows users to filter records based on certain
criteria (via the built-in filter functions).

I would like to have a button which will open a datasheet view of the
filtered recordset so that the user can export it to excel, word, etc.

I can't just use the built-in Datasheet view because there are subforms
on the form which contain data that I would need to have available on
the datasheet. I think what I really need is the ability to save the
current recordset as a query so that I can display the resulting
records, but am unsure as to how to do it.

Try the following:
Create another form that contains all columns that need to be exported.
In the event procedure of the button on the first form, enter this:
DoCmd.OpenForm "OtherForm", acFormDS, , Me.Filter
 
Back
Top