I've written the following macro. The problem is that the report doesn't run. It hangs at the prompt and I have to manually hit "OK" for the report to run and complete the execution of the macro. What am I missing? Thanks.
Sub Main()
Dim objImpApp As object
Dim objImpRep As Object
Set objImpApp = GetObject("CognosImpromptu.Application")
objImpApp.Visible True
Set objImpRep = _
objImpApp.OpenReport("s:\imp71_reporting_tools\joe's reports\green book\" & _
"03-ORG Calendarized GB.imr","30.2|2")
objImpRep.Print 1
Set objImpApp = Nothing
Set objImpRep = Nothing
End Sub
Sub Main()
Dim objImpApp As object
Dim objImpRep As Object
Set objImpApp = GetObject("CognosImpromptu.Application")
objImpApp.Visible True
Set objImpRep = _
objImpApp.OpenReport("s:\imp71_reporting_tools\joe's reports\green book\" & _
"03-ORG Calendarized GB.imr","30.2|2")
objImpRep.Print 1
Set objImpApp = Nothing
Set objImpRep = Nothing
End Sub