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

renaming parameter name in value prompt

Started by Universe09, 18 Mar 2009 09:02:14 PM

Previous topic - Next topic

Universe09

hi,

I tried using HTML item to rename a parameter name in a value using this javascript

<script>
   document.formWarpRequest._oLstChoicesXXX[0].text = 'My own text';
</script>

where the XXX is the name of the value prompt, it is working when I open the report but if I will try to retrieve data the renamed parameter will go back to its original form.

how can I fix that it will always carry the customized text even I try to retrieve data?

please help me... Thanks!

Sunchaser

Hi,

First, "_oLstChoices" is a 8.2 syntax, so you shouldn't expect anything good in 8.3 with that.

You could try to put the code changing the "text" property of your object in a function that will be called each time the page is loaded.
May be you can take a look at this subject:

http://www.cognoise.com/community/index.php/topic,6245.0.html

and see the "body" tag (with onload, etc...).

If I correctly understand what's happening, the page is reloaded each time you retrieve datas.

If not, may be we could imagine to do a 'attachEvent("onChange", function()...etc...)' in the onload event of the body; so, everytime the prompt object is "rebuild", you could be sure that the parameter name will be changed.
But it is not a so "clean" solution, in my opinion...

Hope it could help you.
vinc.