tostrowski
MIS
I am trying to access a Catalog within Impromptu using a macro, but I am having a little bit of trouble. I am a basic user of the program, and I think that that might be the problem or it might be that I need to use my login information. I have left the code below. Any suggestions on how to get this macro to open the catalog and then the report?
Sub Main()
Dim objImpApp as Object
Dim objImpRep as Object
Set objImpApp = _
CreateObject("CognosImpromptu.Application")
objImpApp.OpenCatalog _
"I:\catalog\USS MACS COS.cat", "User"
Set objImpRep = _
objImpApp.OpenReport("E:\Commercial\Impromptu Requests\MACS_COS_TRADE.imr")
objImpRep.RetrieveAll
objImpRep.ExportASCII("c:\Tradecos.csv")
objImpRep.CloseReport
objImpApp.Quit
Set objImpRep = Nothing
Set objImpApp = Nothing
End Sub
Sub Main()
Dim objImpApp as Object
Dim objImpRep as Object
Set objImpApp = _
CreateObject("CognosImpromptu.Application")
objImpApp.OpenCatalog _
"I:\catalog\USS MACS COS.cat", "User"
Set objImpRep = _
objImpApp.OpenReport("E:\Commercial\Impromptu Requests\MACS_COS_TRADE.imr")
objImpRep.RetrieveAll
objImpRep.ExportASCII("c:\Tradecos.csv")
objImpRep.CloseReport
objImpApp.Quit
Set objImpRep = Nothing
Set objImpApp = Nothing
End Sub