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!

Filter Definition on Impromptu Reports using VB

Status
Not open for further replies.

Chargrams

Programmer
Aug 28, 2002
29
0
0
CA
Hi,

I am in great need of a way to automate changing the filter definition of a report through Visual Basic.

I looked at the Impromtu object model and haven't found a way to access this property. I am interested in changing the filter definition, which is located under the filter tab in the Query for that report, using OLE automation in Visual Basic 6.0.

Please Help! [pipe]
 
Hi,

I have not found a way to change the filter definition using VB. However, you can change certain parameters by using prompts. This is one method I use.

If you do find a way, please share this with us. Too bad Cognos can't find away to do this. This would allow for greater flexibility.

Paul
 
There is no API exposure of data filtering at the report level. You can also filter data at the catalog level, but it doesn't sound like this is what you need. The catalog filters also are not exposed in the API.

As was mentioned you can pass prompts in VB or the Cognos macro language. You can also program the report to filter on different columns dynamically via the prompts. This combination may be powerful enough for you needs.

HTH,

Dave Griffin
The Decision Support Group
Reporting Consulting with Cognos BI Tools
"Magic with Data"
[pc2]
 
Hi, Thanks for the help!

I've passed paramters for reports that include prompts but I need filters hardcoded for reports that don't have prompts and might be scheduled. The architecture of my reports wasn't done very well and this is a temporary work-around until I can restructure the reports myself.

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top