Unpredictable Print Sequence

ndeans

Registered User.
Local time
Tomorrow, 04:43
Joined
Jun 5, 2006
Messages
39
I have a niggling printing issue but some background first.

First thing - my reports are NOT summary reports therefore i have no grouping levels etc etc. Each report is specific to a "Health Test". A full "Health Assessment" contains multiple Health Tests.

eg Health Assessment A consists(Test A, Test B & Test C) while Health Assessment B consists(Test A, Test C & Test F).

I have a print report macro that steps through each Test, determines if the Test was completed as part of the overall assessment and then either prints the test report or skips the test report (True = Print, False = Skip). The test reports are printed to the default system printer which is a PDF printer emulation (Cute PDF) as it appends each report as it is printed resulting in a multiple page assessment report rather than a series of individual PDF Reports.

My problem is that i often find the reports are not printed in the same step order that they appear in the macro.

eg. Macro print order is (Report A,B,C,D,E,F etc) but the actual print order might be (Report A,B,D,C,E,F etc)

Each report is generated based on Queries that are linked by Client ID and an Assessment ID. Many of these queries have varying degree's of calculations involved.

I think maybe occasionally Access gets caught up running the calculations of one report and starts running the print for the next report before finishing the previous report. (Just guessing)

I am wondering if there is anyway to put a refresh/requery action in the macro between print actions? OR maybe a time delay?

This is a real thorn in my side as the Boss picks this type of thing up very quickly, so any assistance or idea's would be greatly appreciated.

Cheers
Nathan
 
Macro's are really not the best idea... they limit what you can do.

I have a print report macro that steps through each Test, determines if the Test was completed as part of the overall assessment and then either prints the test report or skips the test report (True = Print, False = Skip)

How are you testing to see if the test has been completed?

It sounds to me (based on the info you've posted) that you should be able to simply create a query which only shows the tests that = true, base the report on that query and print it as one report to 1 PDF...

I may be missing something though.
 
If you have local control over your printer, you need to see if it is using an optimization algorithm for queues.

You see, queue theory says that you can choose a goal and optimize your choice of the next job to print. But that would make the jobs come out of order. So you will have to play around with your PRINT functions (in WINDOWS, not ACCESS) to assure proper observation of this sequence.

In Q theory, you have a concept called SPT, or shortest processing time, tht is basically an estimate of how long each job will take to complete. One of the measures of performance you can use for the basis of queue optimization is either "shortest wait time" or "maximum jobs throughput in an arbitrary period." For either of these, when the queue is ready to start a new job and more than one is ready, you select the shortest job next.

Do this experiment. Look at the sizes of your reports A, B, C, D, ..., etc and see if the order is A, shortest of (B, C, D, etc.), shortest of (whatever remains after 2nd job), and so on. If so, your queue is set for SPT optimization and you must change this behavior in Windows from your control panel and the printers/faxes section.

If you bring up the queue for the active printer WHILE IT IS PRINTING, you can see the sizes of the job and can actually watch when the print queue manager selects another job. It is also from that window that you can control preferences in queue scheduling.

Note that if you did this a different way such that all files were concatenated into a single output file, you could control the order of output. I'm not suggesting that this is an easy task. If you do the experiment and I'm right, reply back here if you can't find the printer queue setting.
 
THis may very well be the solution i'm looking for. Unfortunately i have a boss who thinks we're all 3 years old and therefore we don't have access rights and therefore can't make these changes straight away. Once she gets some time i'll arrange for these changes and give it a try.

Thanks for your assistance.

Cheers
ndeans
 

Users who are viewing this thread

Back
Top Bottom