CarysW
Complete Access Numpty
- Local time
- Today, 12:17
- Joined
- Jun 1, 2009
- Messages
- 213
I'm trying to export labels as a report based on the results of a search (I need to export the labels to Word on request from the end-user).
My search consists of a search form with all fields and a 'Search' button, clicking the Search button brings up a Search box with a combo box and a text box, this is where the search is performed - the results are then shown on the search form, with next and previous buttons.
I have a button on the Form to create labels which ideally will export the predesigned report to Word. But I can't get it to do this - I have first tried just opening the report in Access using this code:
But even this just brings up all entries in the query.
And as I said, ideally it will export the report but as far as I can see there is no 'Where' in the OutputTo command
What am I doing wrong?
My search consists of a search form with all fields and a 'Search' button, clicking the Search button brings up a Search box with a combo box and a text box, this is where the search is performed - the results are then shown on the search form, with next and previous buttons.
I have a button on the Form to create labels which ideally will export the predesigned report to Word. But I can't get it to do this - I have first tried just opening the report in Access using this code:
Code:
DoCmd.OpenReport "rptSearchLbl", acViewPreview, , GCriteria
And as I said, ideally it will export the report but as far as I can see there is no 'Where' in the OutputTo command
What am I doing wrong?