Can't hide Property Sheets

J

James

Software: Access 2007 with 2002/2003 file format.

Goal: Do not show report property sheet during visual basic editing of
report.

Problem: Report property sheet is still appearing when open a report in
design mode in Visual Basic even though use both Echo False and SetWarnings
False

Review of Office Help: The help for “Echo Macro Action†indicates
“The Echo action doesn't suppress the display of modal dialog boxes, such as
error messages, or pop-up forms, such as property sheets. You can use dialog
boxes and pop-up forms to gather or display information, even if echo is
turned off. To suppress all message or dialog boxes except error message
boxes and dialog boxes that require the user to enter information, use the
SetWarnings action.

If taken literally the above indicates that SetWarnings will not hide pop-up
forms such as property sheets. What does?

Example of Code resulting in Undesired Result:
....
DoCmd.Echo False
DoCmd.SetWarnings False
DoCmd.OpenReport "rpt_BO-AllBDActivity", acDesign
....
 
M

Marshall Barton

All I can think or is that
DoCmd.RunCommand acCmdProperties
toggles the property sheet. But that raises the question of
how to find out if it's on or off so I consider it useless
in your case.

OTOH. you should only be using design view when you are
using wizard like code to help YOU modify reports. In that
case, why should you care if the property sheet is visible
or not?

If this is happening in a running application, then I have
to say that you should NEVER revert to design view as part
of any user scenario. That is a really, really BAD thing to
do in any running database. Besides, whatever you need to
do in a running application can be done by setting
properties, usually easier and faster.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top