Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Print preview will not print to printer

Status
Not open for further replies.

BRP250

Programmer
Sep 18, 2001
33
AU
Using Access 2000. In my report in the onpage procedure I have written code to print directly to the page i.e.
me.currentx = ...
me.currenty = ...
me.print recordset.field().value
'draw a box around it
'get the next record

This is fine to view in print preview looks great but not printing to printer. All I get are blank pages.

Anybody know what's happening?

Also within the onpage procedure I call other procedures that actually do the printing ie print the heading then print the data; could this cause the problem?

Bruce
 
Bruce
A couple of questions...

1. Is there a subreport involved?
2. Is the data being assembled with criteria being passed from a form? If so, is the form being closed when the report is opened?

Tom
 
Tom

1. There's no subreport
2. There is a form that opens the report but at the moment I'm not using it.

I have bound the report to a query for report header information. This has controls etc. I open a crosstab query to to get the data to print the information.

I'm now experimenting (unsuccessfully) with putting the code directly into the Detail_Print procedure.

Thanks

Bruce
 
Bruce
I was thinking that if the form had text boxes in which data was put as parameters for the query, and the form was closed when the report opened, then the formatting of the data wouldn't stick upon print.

Still seems to me that the data source is somehow closing before the OnPrint event.

Good luck.

Tom
 
Tom

Thanks, that gives me avenue to check.

Bruce
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top