Currently I'm working in Cognos v10.1.2 . I do have a requirement that the report page name (The worksheet name of the report's excel output) should dynamically change based on the prompt value selected. How could we achieve this in Cognos. Thanks in advance for your help.
Asked
Active
Viewed 5,692 times
2
-
1Nope. It just uses the page name in the report plus _1, _2, etc. – Andrew Nov 25 '13 at 21:54
-
@Andrew, Thanks for the reply. I've one more doubt. Is it possible to control any object using the id and JavaScript in Cognos? example: Consider that we have a list in the report and the name is list1 by default. Could we access it in JavaScript? like GetElementbyID("list1") – arunpandiyarajhen Nov 26 '13 at 03:52
-
I don't think I've ever tried to do anything like that. How would you fire the event to rename the list? I don't think can rename it from a prompt page. I guess maybe you could add an HTML item to the report page (assuming you're running to HTML) and fire your JavaScript using the OnExit property. – Andrew Nov 26 '13 at 04:09
-
No you can't do that with JavaScript - it's a client side script that knows nothing about report studio or Excel. You could conceivably write some VBScript or something to rename Excel sheets after the fact. You could also create report pages for every requirement, and only render the required ones based on the prompt. That would do what you need though you'd still have _1 on the end. – Nick.Mc Dec 02 '13 at 04:07
-
Try this: put macro in PageName field, like: `#PROMPT('MyParameter','text','DeafultValue')#` (may be not precise code). – Stoleg Aug 21 '14 at 21:46
-
It will take it #PROMPT('MyParameter','text','DeafultValue')# as a report name. – arunpandiyarajhen Aug 22 '14 at 13:55
2 Answers
3
I believe you can accomplish this in a variety of ways
For example, grouping mechanisms and RSVP.EXCEL.PAGEGROUP_WSNAME_ITEMVALUE is set to true
Also you can do this with rendering and page set definitions

VAI Jason
- 534
- 4
- 14
1
Unfortunately not, you would have to create separate pages for each code and have them render only if those cards are not missing

Charley
- 11
- 2