Hi,
My requirement is that i have two textbox prompts and i have to give an option to the user that he has to enter atleast one value. We don't know which value he enters. so, I'm trying to inplement a javascript in which it validates both the prompts and check the values in them. if there is no value, then it will no go into the report page.
Everything seems to work okay.. but i got a problem in fectching the value in the textbox prompt into the parameter.
Attahced is my script for the same.
My logic to fetch the value is
par1 = document.formWarpRequest.elements["p_provider_id"].value
i think there is a mistake in this syntax.
Please correct it.
Thanks in Advance
Hope you solved this long back. Still posting it coz, it might help others.
par1 = getFormWarpRequest()._textEditBoxp_provider_id.value;
Gopi,
Thanks alot for the help. i didn't get any solution for this till today.
I modified the one that you sent to
par1 = document.formWarpRequest._textEditBoxp_provider_id.value;
and it worked.
Thank you
Desperado you must bear in mind that when you upgrade to 8.4 your JavaScript will have to change. Your best bet is package all your JavaScript utility functions into a library and include them in every page via the standard <script> html tag. Then when Cognos changes their JS implementation you only have to update your library once, and not go through every report and update it.
Of course this wont be an issue of it just one report.
Is there any way to grab parameter value using Java script
i know we can access paramater in page by p_<ParameterName>
I don't how to grab the value and check condition in the script based parameter value