COGNOiSe.com - The IBM Cognos Community

Legacy Business Intelligence => COGNOS ReportNet => Report Studio => Topic started by: mrcool on 31 May 2007 10:51:10 AM

Title: how to pass 1st value as default value in value prompt
Post by: mrcool on 31 May 2007 10:51:10 AM
Hi Frnds,

              Iam using java script below to show the 1st value in prompt as default value.But the problem is
the script just shows r displays in thevalue prompt as def value....but its not passing that value to the parameter in the report.

<script>document.formWarpRequest._oLstChoicesP.selectedIndex = 2;</script>
This is the script am using...
Plz help me out frm this problem....
Thanks in advance

Mrcool
Title: Re: how to pass 1st value as default value in value prompt
Post by: Desperado on 04 Jun 2007 08:53:24 AM
document.forms["formWarpRequest"].elements["_oLstChoicesP"].selectedIndex = 2;
setTimeout('listBoxP.autoSubmit()', 100);

This is working :)
Title: Re: how to pass 1st value as default value in value prompt
Post by: mrcool on 04 Jun 2007 09:52:14 AM
Thank u..... :D