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

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

JavaScript function to show parameters and their values

Started by borco, 01 Dec 2015 01:31:54 AM

Previous topic - Next topic

borco

Hello all,

I'm looking for a Cognos JavaScript function that return the report's parameters and their chosen values by the user.

Does anyone know such a function.

Thanks in advance,

Or

bdbits

If this is on the report page, there are built-in functions to display them - ParamNames(), ParamValue(), ParamDisplayValue().

If it is on the prompt page for validation or whatever, see the prompt API especially cognos.Prompt.getControls and cognos.Prompt.Control.getValues.

https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0ahUKEwjIn5mEgrvJAhUD82MKHXtBDVIQFggfMAA&url=https%3A%2F%2Fwww-304.ibm.com%2Fsupport%2Fknowledgecenter%2FSSEP7J_10.2.2%2Fcom.ibm.swg.ba.cognos.ug_cr_rptstd.10.2.2.doc%2Fc_prmpt_api_overview.html&usg=AFQjCNHcJCtNCG5_c46AUiFkX1xZXEvM3g&cad=rja

borco

Hi,
Thanks for your reply. This is a report page but I need something Generic because I can't know what parameters are being used.
This is a template report that other reports are using and each report has its own parameters.
Any ideas?

bdbits

The only thing I can think of that might work is parsing out ParamNames() in conjunction with ParamValue() and ParamDisplayValue(). As I have not used ParamNames() I am sadly not much help, but that is where I would start.

If you get something working, I am sure the Cognoise community would love to see it.  ;)