Printing Query

lerwane

Registered User.
Local time
Today, 20:16
Joined
Jan 9, 2004
Messages
22
is it possible to call the query option? meaning in printing the report, instead of using TABLE, im going to get the data from QUERY.

what would be the sql statement then?

please help!

Thanks
 
lerwane,

A query is just a set of directions for how to fetch data from
tables. Open a new query, choose your table, add the fields
and save it as qryMyReport.

Then with the Report in design view, select the query as the
Record Source from the drop-down list.

Do your sorting and summing in the report.

Wayne
 
yah i did that already.

my question now is, what would be the code or script that i will put in opening the record?

isn't it there's an "Event Procedure" to be put then there should be a code for opening the report?

what would it be?

please help!
 
lerwane,

The only code that you need will be for a command
button that your put on some form to launch the
report.

You use the OnClick event of the button to put:

DoCmd.OpenReport "YourReport"

The report will open, and if you have set its
record source to some query, you'll be all set.

Wayne
 

Users who are viewing this thread

Back
Top Bottom