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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening Reports in VBA

Status
Not open for further replies.

rpbenito

Programmer
Jun 13, 2001
63
US
How do I open a report in VBA and have it pop up in the front window on top of all the other forms open?

Thanks


Pat
 
Thanks, but that code only prints the report...the code I'm using is

DoCmd.OpenReport "contact_general_info", acViewPreview

it opens the report up to view, but behind the current form. I need it to open up in front of the current form...thanks in adcvance...

Pat
 
After the command to open the report, insert:

DoCmd.SelectObject acReport, "contact_general_info", False

This selects the report as the active object.
 
Thanks for the help, but after inserting the line of code nothing changed. Any other suggestions?
 
Check the properties for the forms and make sure that none of them are set to "popup".

Popup forms will still show on top of active objects.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top