COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: hrk551 on 15 Apr 2009 02:56:53 PM

Title: To change te data item name in a value prompt
Post by: hrk551 on 15 Apr 2009 02:56:53 PM
In a value prompt the first item shown is the data item name i.e (Country_Desc), I need to customize this to ("ALL COUNTRIES). I used the following script it works for the first time but when we reprompt this name again comes back to the data item name.
<script>
   document.formWarpRequest._oLstChoicesIID[0].text = 'YOUR TEXT';
</script>

I am using 8.3 ........


Thanx in Advance....
Title: Re: To change te data item name in a value prompt
Post by: cognos_guru on 15 Apr 2009 03:28:24 PM
Why don't you just use a multiple value prompt and allow the user to select some or all of the countries?
Title: Re: To change te data item name in a value prompt
Post by: hrk551 on 16 Apr 2009 08:25:35 AM
Thank you for your reply Cognos_Guru.

But,I this is not the case for milti-select. When a data item is taken as a use value the name of that data item comes as first item in the drop down onselecting that displays the whole countries (in my example) , i need to change only that name .....
Title: Re: To change te data item name in a value prompt
Post by: Gopinath on 16 Apr 2009 08:48:48 AM
Hi,

Just add one more data item in the query and drag and drop Country_Desc data item as the expression.

Use the new data item as the use and display value for your prompt. Rename the prompt parameter to 'ALL COUNTRIES'.

done.