Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Database Window tweaking performance of cmds

Status
Not open for further replies.

bill1one

Programmer
Sep 29, 2004
93
US
I have a menu that opens different reports. Here is the code for those reports.

Sub OpenRpt_Open()
DoCmd.Close acForm, "frmMenu", acSaveNo
DoCmd.Maximize
End Function

Sub CloseRpt_Close()
DoCmd.Restore
DoCmd.OpenForm "frmMenu", acNormal
End Function

What is wierd is that they work fine if the Database Window is displayed, but if I do not display the Database Window at startup, then the reports won't maximize like they should.

Any suggestions?
 
Try msximizing before the form closes:

Code:
Sub OpenRpt_Open()

    DoCmd.Maximize
    DoCmd.Close acForm, "frmMenu", acSaveNo
    
End Function

If that does not work look into the SelectObject method.


TomCologne
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top