469,568 Members | 1,547 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,568 developers. It's quick & easy.

Printing Reports generated from Temporary Tables

I am having problems printing some reports from my application that are generated from temporary tables. The application has an Access FE and a SQL Server BE.

The current method uses a temporary workspace. This workspace uses ODBCDirect which bypasses the JET engine completely. However, these objects are temporary and are destroyed at the end of the function. In order to get the reports working I launch the reports before the object is destroyed. Additionally, I use global temporary tables so the two connections (temp workspace and regular DAO PTQ) can see the table. Now, our issue is that the temp table is destroyed after generating the report. When the user wants to print, Access reruns the report (so it appears). However, now, there are no more temp tables.

The "simplest" workaround would be to get Access to print what is on the print preview. But, it seems that Access has to requery everything rather than use the report it already generated. Is that the way it works?

Has anyone come across this issue before and come up with a workaround?

I appreciate and direction and suggestions you may have to my dilemma. Thanks.
Feb 8 '08 #1
1 1747
puppydogbuddy
1,923 Expert 1GB
I am having problems printing some reports from my application that are generated from temporary tables. The application has an Access FE and a SQL Server BE.

The current method uses a temporary workspace. This workspace uses ODBCDirect which bypasses the JET engine completely. However, these objects are temporary and are destroyed at the end of the function. In order to get the reports working I launch the reports before the object is destroyed. Additionally, I use global temporary tables so the two connections (temp workspace and regular DAO PTQ) can see the table. Now, our issue is that the temp table is destroyed after generating the report. When the user wants to print, Access reruns the report (so it appears). However, now, there are no more temp tables.

The "simplest" workaround would be to get Access to print what is on the print preview. But, it seems that Access has to requery everything rather than use the report it already generated. Is that the way it works?

Has anyone come across this issue before and come up with a workaround?

I appreciate and direction and suggestions you may have to my dilemma. Thanks.
You are using the MakeTable query as the record source of your report, so whenever you print the report, the MakeTable query executes again. If you just want a file copy of the same report, output the report as a pdf file to a designated directory, and that file will be available for future reprinting.

If you don't already have a pdf driver for your printer, you can download a free one at the following link. It installs as a printer driver via windows control panel and shows up on your list of printers to select from when you call the printer dialog. http://www.cutepdf.com/
Feb 9 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

2 posts views Thread by airkart | last post: by
3 posts views Thread by Gheaci Maschl | last post: by
3 posts views Thread by carlor | last post: by
reply views Thread by dkurtz | last post: by
5 posts views Thread by dancole42 | last post: by
6 posts views Thread by Josetta | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.