S
SF
Hi,
I have a search form with a few searc criteria, mostly combo boxes, which
working OK. The search form is able to provide result to the listbox on the
form.
The listbox rowsource is derived from the query string (eg SELECT
rptTrainingInvemtoryDatasheet.* FROM rptTrainingInvemtoryDatasheet WHERE
[Province] Like '*Battambang*' and [Topic] Like '*Conflict Resolution*')
Now user want to export the search result to Excel and I add a button on the
form to do this task. I got error from line below as my queryname is
actually a text
DoCmd.OutputTo acOutputQuery, MySQL, acFormatXLS, "TRAINING INVENTORY.XLS",
True
Do I have to create query first in order to export the result?
SF
I have a search form with a few searc criteria, mostly combo boxes, which
working OK. The search form is able to provide result to the listbox on the
form.
The listbox rowsource is derived from the query string (eg SELECT
rptTrainingInvemtoryDatasheet.* FROM rptTrainingInvemtoryDatasheet WHERE
[Province] Like '*Battambang*' and [Topic] Like '*Conflict Resolution*')
Now user want to export the search result to Excel and I add a button on the
form to do this task. I got error from line below as my queryname is
actually a text
DoCmd.OutputTo acOutputQuery, MySQL, acFormatXLS, "TRAINING INVENTORY.XLS",
True
Do I have to create query first in order to export the result?
SF