COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: bbrooksux on 25 Nov 2009 02:59:34 PM

Title: Get Select all to show up in a layout calculation prompt summary
Post by: bbrooksux on 25 Nov 2009 02:59:34 PM
I'm working on several reports where we have built a layout calculation to deliver the parameter/prompt selections within the report to show the viewer what they've selected.  One thing the report requester is wanting to add is the ability to show the text 'All items selected' in the report results if the user clicks the "Select All" link during prompt selection.  Below is the layout calculation we're using in the expression definition to this point.  Does anyone know how we would need to modify the definition in order to get this to function properly?

if (ParamCount(ParamName('prompt'))>15)                                 
THEN ('Greater than 15 selected')                                       
ELSE                                                                   
(ParamDisplayValue('prompt'))
Title: Re: Get Select all to show up in a layout calculation prompt summary
Post by: mgibson on 25 Nov 2009 09:46:57 PM
We do things a little differently.  We set the prompt as Optional, and encourage users to select 'Nothing' if they wish to see all items (i.e. we include these instructions on the prompt page).  Then we display 'All', where the prompt parameter is Null.

Regards
Mick
Title: Re: Get Select all to show up in a layout calculation prompt summary
Post by: vinu on 25 Nov 2009 11:58:57 PM
HI,

use java script or static choice to create 'All items Selected' text in your prompt.

and you can try below in your layout calculation.

Case
when (ParamCount(ParamName('prompt'))>15) then ('greater than Fifteen selected')
when (ParamDisplayValue('prompt')='All items selected') then ('All items selected')
else ParamDisplayValue('prompt')
End

Regards,
Venu.