Go Back   Access World Forums > Microsoft Access Discussion > Reports

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 12-01-2018, 01:12 AM   #16
isladogs
Part time moderator
 
isladogs's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 7,439
Thanks: 92
Thanked 1,831 Times in 1,701 Posts
isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light
Re: Report not printing correctly

I usually find the solutions to odd problems like this come to me in a flash of inspiration when I'm away from the computer e.g. walking the dog or just as I'm falling asleep (which of course wakes me up again....)

Anyway. I'm sure the OP will be suitably grateful.... it will save a fortune on ink when printing

__________________
If this answer has helped, please click the Thanks button and/or click the 'reputation scales' symbol on the left.

Website links:
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


Colin
Previously known as ridders : Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
isladogs is offline   Reply With Quote
Old 12-01-2018, 01:21 PM   #17
June7
Newly Registered User
 
Join Date: Mar 2014
Posts: 956
Thanks: 0
Thanked 215 Times in 215 Posts
June7 will become famous soon enough
Re: Report not printing correctly

I think qryData should probably be RIGHT instead of INNER joins. This will result in 29 records in query.

OP said requirement was for 24 lines per page. Report generates infinite pages if I input 24 in the combobox. First page has 23 records, second has 5 records, 1 record is lost.

rptPTSB design won't allow 24 records per page. 23 will work. Need to reduce Detail section height just a little, as in rptPTSBAWF, which does allow 24 records per page. Set PageBreak control Top to 0.25 and the Detail section Height to 0.25 as well.

I am annoyed that I cannot get Lesandrini's original code from the web page to work.
__________________
To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression. Attachment Manager is below Advanced editor window, click Go Advanced below Quick Reply window.

Last edited by June7; 12-01-2018 at 02:03 PM.
June7 is offline   Reply With Quote
Old 12-01-2018, 08:50 PM   #18
JHB
Have been here a while
 
Join Date: Jun 2012
Location: In the south of Denmark (Jutland), near the German border.
Posts: 7,472
Thanks: 2
Thanked 2,003 Times in 1,959 Posts
JHB has a spectacular aura about JHB has a spectacular aura about
Re: Report not printing correctly

Quote:
Originally Posted by June7 View Post
..
I am annoyed that I cannot get Lesandrini's original code from the web page to work.
Is it the code in post #4 you mean?
If yes, then the code is missing the part where the last record has been reached and the page is not yet fully filled.
Because when the last record is reached, the printing stops, (report finish).

__________________
If the above post has helped you, why not take the time to say thank you, by pressing the "Thumbs up."
JHB is offline   Reply With Quote
Old 12-01-2018, 09:02 PM   #19
June7
Newly Registered User
 
Join Date: Mar 2014
Posts: 956
Thanks: 0
Thanked 215 Times in 215 Posts
June7 will become famous soon enough
Re: Report not printing correctly

No, post 4 is different code. It works as long as there is only 1 page full or less of records. I tested on a report that allows 50 lines.

Here is the code OP adapted https://www.vb123.com.au/200310_dl_pad.htm
__________________
To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression. Attachment Manager is below Advanced editor window, click Go Advanced below Quick Reply window.
June7 is offline   Reply With Quote
Old 12-05-2018, 03:53 PM   #20
sprijohn
Newly Registered User
 
Join Date: Oct 2018
Location: Evanston, WY, USA
Posts: 11
Thanks: 6
Thanked 0 Times in 0 Posts
sprijohn is on a distinguished road
Re: Report not printing correctly

Thank You, Thank You, Thank You, JHB!!!

Your Change in the code at the beginning of the Detail_Format Section got it to finally print (At least to a PDF).

I did discover that Print Preview was allowing the report to never exit the module. Clicking on the next page icon created another new page which did not contain data. I changed the last if statement in the datail_format subroutine from "If iLine <> iRptLines Then Me.NextRecord = False" to "If iLine < iRptLines Then Me.NextRecord = False" to force the subroutine to exit once the number of lines printed equaled or exceeded the number of lines needed to give 24 line per page.

The only problem left is that the report is now printing one extra blank line for each page printed in the report. Since these are on the last page it could work. That is unless there are a lot of names to be printed.

I stripped down the DB to focus on the print routine. I also cleaned up the report and the test data to more closely match what I am attempting to accomplish in the production DB. Please see attached file.

This is very close to being finished. Any suggestion on how to control the extra lines would be greatly appreciated.
Attached Files
File Type: zip Blank_Lines_Test.zip (120.3 KB, 6 views)
sprijohn is offline   Reply With Quote
Old 12-05-2018, 04:03 PM   #21
isladogs
Part time moderator
 
isladogs's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 7,439
Thanks: 92
Thanked 1,831 Times in 1,701 Posts
isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light
Re: Report not printing correctly

sprijohn
For info I've just deleted 4 identical copies of your last post which were all moderated. That usually happens when new users post unzipped attachments.
Whatever the reasons, if a post doesn't appear in future, please click the red triangle button to report the issue and a moderator will follow up fairly quickly.
Don't keep posting duplicate posts. Thank you
__________________
If this answer has helped, please click the Thanks button and/or click the 'reputation scales' symbol on the left.

Website links:
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


Colin
Previously known as ridders : Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
isladogs is offline   Reply With Quote
The Following User Says Thank You to isladogs For This Useful Post:
sprijohn (12-05-2018)
Old 12-05-2018, 04:14 PM   #22
sprijohn
Newly Registered User
 
Join Date: Oct 2018
Location: Evanston, WY, USA
Posts: 11
Thanks: 6
Thanked 0 Times in 0 Posts
sprijohn is on a distinguished road
Re: Report not printing correctly

Sorry, my bad. I kept getting interrupted at work and I had too many tabs open. The site kept asking me to log in and when I did not see the first post I was afraid it was lost. I wasn't able to read the posting delay notice when I placed the original post because it flipped thorough too fast. I was not aware that the red triangle was for communicating issues with a moderator. Suffice it to say,lesson learned, it should not happen again.

sprijohn is offline   Reply With Quote
Old 12-05-2018, 04:37 PM   #23
isladogs
Part time moderator
 
isladogs's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 7,439
Thanks: 92
Thanked 1,831 Times in 1,701 Posts
isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light
Re: Report not printing correctly

No worries & I'm very pleased to see JHB's solution worked for you.
__________________
If this answer has helped, please click the Thanks button and/or click the 'reputation scales' symbol on the left.

Website links:
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


Colin
Previously known as ridders : Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
isladogs is offline   Reply With Quote
Old 12-05-2018, 06:38 PM   #24
JHB
Have been here a while
 
Join Date: Jun 2012
Location: In the south of Denmark (Jutland), near the German border.
Posts: 7,472
Thanks: 2
Thanked 2,003 Times in 1,959 Posts
JHB has a spectacular aura about JHB has a spectacular aura about
Re: Report not printing correctly

Quote:
Originally Posted by sprijohn View Post
Thank You, Thank You, Thank You, JHB!!!
You're welcome.
Quote:
Originally Posted by sprijohn View Post
..
The only problem left is that the report is now printing one extra blank line for each page printed in the report. ..
Any suggestion on how to control the extra lines would be greatly appreciated.
The problem is the total height of the report, if you move the text in the "Page Header" a little up, (and shrink the section height), the problem should be solved.
Attached Files
File Type: zip Blank_Lines_Test.zip (53.3 KB, 5 views)
__________________
If the above post has helped you, why not take the time to say thank you, by pressing the "Thumbs up."
JHB is offline   Reply With Quote
The Following User Says Thank You to JHB For This Useful Post:
sprijohn (12-06-2018)
Old 12-06-2018, 07:47 AM   #25
sprijohn
Newly Registered User
 
Join Date: Oct 2018
Location: Evanston, WY, USA
Posts: 11
Thanks: 6
Thanked 0 Times in 0 Posts
sprijohn is on a distinguished road
Re: Report not printing correctly

Thanks, JHB.

Resizing did the trick. This problem in now finally solved! Anybody know how to mark this thread as "Solved"? If anyone is interested in the final product please see attached file.

The sign-in sheets are printing properly. Thanks again to all those who helped.
Attached Files
File Type: zip Blank_Lines_Test.zip (52.6 KB, 3 views)
sprijohn is offline   Reply With Quote
Old 12-06-2018, 07:52 AM   #26
isladogs
Part time moderator
 
isladogs's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 7,439
Thanks: 92
Thanked 1,831 Times in 1,701 Posts
isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light isladogs is a glorious beacon of light
Re: Report not printing correctly

Ah! I can tell you that!
Click on Thread Tools drop down in the blue bar above and tick the box

__________________
If this answer has helped, please click the Thanks button and/or click the 'reputation scales' symbol on the left.

Website links:
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


Colin
Previously known as ridders : Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
isladogs is offline   Reply With Quote
The Following User Says Thank You to isladogs For This Useful Post:
sprijohn (12-06-2018)
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Report not printing correctly? Mist Forms 0 08-01-2012 02:35 PM
Access made PDF not printing correctly LB79 Modules & VBA 3 07-27-2012 12:19 AM
Report not printing correctly... steveo_biggame Reports 1 11-19-2009 05:15 AM
Print Preview Wonky but Printing Correctly shewolf Reports 2 03-02-2007 03:27 PM
Report based on qry not printing correctly mousemat Reports 2 08-28-2006 07:56 AM




All times are GMT -8. The time now is 11:53 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Featured Forum post


Sponsored Links


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World