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

Hold code execution

Status
Not open for further replies.

AndreAraujo

Programmer
Feb 14, 2002
62
PT
Hi,
I'm a having a problem with 2 reports, i have to print 2 reports , but the users need to preview the first report and print, and only then see the preview of the second report.
Is there a way to hold the program until the print of the first report????

Thanks in advance
André Araujo

 
Put the "OpenReport" command in the "OnClose" event of the first report.
;-)


Andreas Galambos
EDP / Technical Support Specialist
(andreas.galambos@bowneglobal.de)
HP:
 
Hi, i get the solution from a thread by Trevor Best.

DoCmd OpenReport "rptWhatever", A_PREVIEW
Do While IsReportLoaded("rptReport")
DoEvents
Loop
DoSomeThingElse

Function IsReportLoaded(pstrReport As String)
IsReportLoaded = SysCmd(SYSCMD_GETOBJECTSTATE, A_REPORT, pstrReport)
End Function

Thanks everyone, Andreas Great tip.


André
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top