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

Macro Impromptu reports catalog path

Status
Not open for further replies.

kejalg

Technical User
Sep 14, 2003
12
0
0
IN
Hi,

Does anybody know how to get the catalog path of the report and change it using macro?

Thanks
Kejalg
 
kejalg,

The .CatalogName property will return the file name. The easiest way to change the catalog in a report is to open it with another compatible catalog already open and save it. This can be done easily via a macro.

Regards,

Dave Griffin


The Decision Support Group
Reporting Consulting with Cognos BI Tools
"Magic with Data"
[pc2]
Want good answers? Read FAQ401-2487 first!
 
kejalg,

This will return the catalogname in a msgbox.

Sub Main()
Dim objImpApp As Object
Dim strCatName As String
Set objImpApp = getObject("CognosImpromptu.Application")
strCatName = objImpApp.CatalogName
If strCatName <> &quot;&quot; Then
Msgbox &quot;The currently open catalog is:&quot; & strCatName
Else
Msgbox &quot;No catalog is currently open.&quot;
End If
Set objImpApp = Nothing
End Sub

hope it's helpfull

greetz,

Martijn
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top