D
DS
How do you turn off the box that comes up when you prin that says...
Printing Page 1 etc.....
Thanks
DS
Printing Page 1 etc.....
Thanks
DS
Thanks, I tried that and it didn't work....perhaps the reason it didn'tWayne said:This will depend in part on whether this is the Windows dialog or one
generated by your printer driver. If it is the Windows dialog, see this
article:
http://www.mvps.org/access/api/api0037.htm
If it's generated by your printer driver, you'll need to see if there is a
setting in the driver to suppress it.
Wayne said:Ok, the code in the first blue box goes where it is mentioned it goes. The
On Timer line on the Events tab of the form's Properties sheet should read
[Event Procedure].
The code in the second blue box goes in the click event of the button you
click to open the report. Adjust the report and form names to match the ones
in your database.
The code in the third blue box goes in a standard module that you would
create in the Modules window of the main database window. Give the module a
unique name, not something that will appear in any procedure (i.e.
basHidePrintDialog). Just copy and paste all of the code in the third blue
box into this module right after the lines "Option Compare Database" and
"Option Explicit". It will automatically break down into the separate
procedures.
If you don't see "Option Explicit", add it right below the line "Option
Compare Database". Also, in the code editor, go to Tools|Options and check
the box "Require Variable Declaration". This will automatically add the line
"Option Explicit" to any new module (standard, form, or report). I would
recommend going back and adding the line to any modules you already have.
This will force you to declare your variables (Dim statements), but will cut
down on typos because the compiler will flag anything you've misspelled
instead of just assuming it to be a new variable.
DS said:Wayne said:Ok, the code in the first blue box goes where it is mentioned it goes.
The On Timer line on the Events tab of the form's Properties sheet should
read [Event Procedure].
The code in the second blue box goes in the click event of the button you
click to open the report. Adjust the report and form names to match the
ones in your database.
The code in the third blue box goes in a standard module that you would
create in the Modules window of the main database window. Give the module
a unique name, not something that will appear in any procedure (i.e.
basHidePrintDialog). Just copy and paste all of the code in the third
blue box into this module right after the lines "Option Compare Database"
and "Option Explicit". It will automatically break down into the separate
procedures.
If you don't see "Option Explicit", add it right below the line "Option
Compare Database". Also, in the code editor, go to Tools|Options and
check the box "Require Variable Declaration". This will automatically add
the line "Option Explicit" to any new module (standard, form, or report).
I would recommend going back and adding the line to any modules you
already have. This will force you to declare your variables (Dim
statements), but will cut
down on typos because the compiler will flag anything you've misspelled
instead of just assuming it to be a new variable.
OK Wayne, it works. But is there any way of speeding it up. I see it
open then I see it reduce. I want to either block it, get rid of it,
replace it with my own form saying "Sending Items", or make it move
quicker.
Thanks
DS
Thanks Wayne,Wayne said:You could try setting the timer interval to something smaller than 300. The
value is in milliseconds, so 300 is 3/10ths of a second. Be careful to not
go too small, I suspect it will cause problems. Try reducing it 50
milliseconds at a time and see what you get, under 100 is probably
questionable. Of course, the speed of the computer and how busy it currently
is will also have an effect.
I don't know if setting Echo to False before issuing the OpenForm command
will help or not since the dialog is a built-in Windows dialog, but you
could try it.
Private Sub Command0_Click()
On Error Resume Next
DoCmd.OpenForm "Form2"
DoEvents: DoEvents: DoEvents
Application.Echo False
DoCmd.OpenReport "Sales by Category", acViewNormal
DoCmd.Close acForm, "Form2"
Application.Echo True
End Sub
Tried both, nothing noticable. How do other applicatins do it? I seeDS said:Thanks Wayne,
I'll play with it and see what I get.
BTW do you know how to monitor the Print Spooler to return a message,
(Preferably a form of my own making) to let the user know a printer is
offline?
Thanks a Million
DS