Hi,
I want to filter a report trough a text prompt and javascript, selecting is Ok, but reseting the parameter is not working, also cognos.Report.getReport: is not available in 8.3, how can do it ?
below the code
<button title="Show Tab 1" onclick="document.formWarpRequest.elements['p_REGION_ID'].value='1';promptButtonFinish();document.formWarpRequest.elements['p_REGION_ID'].value='';">Select 1</button>
<button title="Show Tab 2" onclick="document.formWarpRequest.elements['p_REGION_ID'].value='2';promptButtonFinish();">Select 2</button>
<button title="Show Tab 2" onclick="clearAllValues() ;">RESET</button>
<input type="text" name="p_REGION_ID" value=""/>
<script>
function clearAllValues() {
var oCR = cognos.Report.getReport("_THIS_");
var aControls = oCR.prompt.getControls();
for (var i = 0; i < aControls.length; i++) {
aControls.clearValues();
}
}
</script>