I,m having trouble with a report that is based on a query. In the query the criteria for each field is a function that returns a value(this value changes) from a global variable.
when I run this code...
And go to where the 'order.rtf' file is saved, the report shows no values just the labels.
But when I run:
the report opens and all the values are there.
The global variables are assigned values when the user clicks the order button a call is then made to the
create_order function where the DoCmd.OutputTo acOutputReport....is carried out. The 'order.rtf' file is sent as an attachment. I'm trying to automate the order process.
B
when I run this code...
Code:
DoCmd.OutputTo acOutputReport, report_name, acFormatRTF, "C:\Documents and Settings\Bob\My Documents\Order.rtf"
But when I run:
Code:
DoCmd.OpenReport "order", acViewPreview
The global variables are assigned values when the user clicks the order button a call is then made to the
create_order function where the DoCmd.OutputTo acOutputReport....is carried out. The 'order.rtf' file is sent as an attachment. I'm trying to automate the order process.
B