By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,392 Members | 1,576 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,392 IT Pros & Developers. It's quick & easy.

Report based on Crosstab Query..

P: n/a
I am running Access 2003 on WinXP.
Many of you will think I'm nuts when i explain what I am experiencing. I
have a report that is based on a crosstab query and it works fine. The
user has requested a slight change adding a few different totals at the
end. They should actusall be additional categories but i thought i could
just add some code and pull them out as the report was being poroduced.
I added the code in the ON-PRINT Event and it seemed to work. When I
previewed the report everything looked good. When I print the report the
totals are exactly doubled.
This is happening consistantly and it has happened on two different
computers. It's as if the report is being produced again when it is
printed but the variables are not being cleared. Anybody have any ideas
as to what might be going on?


Tim Hunter

*** Sent via Developersdex ***
Dec 20 '06 #1
Share this Question
Share on Google+
1 Reply

P: n/a
OK, problem solved. This one had me tearing my hair out. This problem
can occur when you use VB behind your reports to hold accumulation
totals. This occured when I previewed the report and found everything
correct but when i printed the report the totals exactly doubled.
The solution is to provide the correct initialization of your variables.
They must be intialized first when the report is opened and then again
when the report is sent to the printer. The names of these two events
are: Report_Open and Report_Page.
I found this answer surfing other sites. I tested it and it works..TIA

Tim Hunter

*** Sent via Developersdex ***
Dec 21 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.