Echo On/Off (1 Viewer)

deadman

Registered User.
Local time
Yesterday, 19:42
Joined
Feb 13, 2002
Messages
23
I have a form with a command button to open a preview of a report. When the command button is clicked on, the form is set to visible=false. When the button is clicked on, what actualy happens is: the form disappears, the database window becomes visible (the list of tables, forms, queries etc. not sure if thats what is called), and then the report preview becomes visible. I know I can eliminate the database window from becoming visible but am not having any luck. The relevant portion of the code I am using for the command button on click is as follows:

If Forms!frmPrintOptions!chk7 = True Then

DoCmd.Echo False, "Opening Report..."
stdocname = "rptReportName"
DoCmd.OpenReport stdocname, acViewPreview
DoCmd.Echo True, ""

End If

What am I doing wrong?
 

David R

I know a few things...
Local time
Yesterday, 19:42
Joined
Oct 23, 2001
Messages
2,633
If you just want to clean up your workspace, go to Tools>Startup and uncheck the database window.
Otherwise, go to the archives and search for 'hide database window', there are quite a lot of other options for doing this sort of thing as well..

Good luck,
David R
 

deadman

Registered User.
Local time
Yesterday, 19:42
Joined
Feb 13, 2002
Messages
23
Thanks for your reply, David. I am just trying to clean things up. I was able to eliminate seeing the database window when using command buttons to close current form and open next form by using the echo settings and thought that this would be possible when opening a preview of a report as well. Just trying to give it a smoother appearance. Thanks again.
 

Users who are viewing this thread

Top Bottom