If you are unable to create a new account, please email support@bspsoftware.com

 

TreePrompts with complete interactivity Reports / dynamically Preset

Started by chinside, 11 Jun 2019 08:20:55 AM

Previous topic - Next topic

chinside

Hello,
I work on reports with multidimensional structures and execute them with complete interactivity.
Here I use the TreeView for the dimensions.
I would like to dynamically pre-set the time dimension with the current month. I am aware that I can do this statically via the default selection values.

I would like to deposit a calculated data element here or similar but I have not found a way.
Also, JavaScript in the "old" way as an HTML element does not work thanks to full interactivity.
I also tried different things with the Prompt API and thought that it could actually work with SetValue.
Here I find contradictory information:

The following is that tree views are not supported
https://www.ibm.com/support/knowledgecenter/en/SSEP7J_11.1.0/com.ibm.swg.ba.cognos.ug_cr_rptstd.doc/c_prmpt_api_overview.html

Here, however, it looks like the bug has already been fixed.
https://www-01.ibm.com/support/docview.wss?uid=swg1PM90679


Anyway, do you have any idea how I can maintain TreeViews dynamically?
Thank you for your help and your time!

CognosPaul

You can use JS with tree prompts, but there are a few limitations.

On the first run the prompt won't have any indication that a value was selected, the prompt won't automatically expand to it. Setting the value does work, and it will set it NEXT time the report is submitted. I recommend using a prompt macro and embedding the default value you want in there.

Take a look at the attached JS.