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

Radio Button onchange javascript not working

Started by scabral79, 15 Jul 2015 05:51:45 PM

Previous topic - Next topic

scabral79

Hi,
i have the following javascript on a radio button prompt:
<script type="text/javascript">
var fW = (typeof getFormWarpRequest == "function" ? getFormWarpRequest() : document.forms["formWarpRequest"]);   
setTimeout('fW.elements["_oLstChoicesQuickSearch"].onchange =  setBufferZone();', 5); 
function setBufferZone()
{
var quickSearchList;
var quickSearchListSelected;
quickSearchList = fW._oLstChoicesQuickSearch;
     for (i=0; i < quickSearchList.length; i++)
     {
          if (quickSearchList.checked)
          {
               quickSearchListSelected = quickSearchList.value;
          }
     }
alert(quickSearchListSelected);
}
</script>
the alert runs the 1st time the page is loaded, but then it will not run again even on change of the radio button.  It seems like the javascript no longer sees the radio button group for some reason.
was wondering if anyone has run into this issue before.  Using Cognos version 10.2.1.
thanks
Scott