Passing a checkbox as a parameter to a javascript function
Hi all,
I'm trying to add some functionality to my report, i hope you can help me. I have in the sql query of the report, amont other things, a checkbox and a select list.
What I want to do, is that when the user changes the value of the select list, it automatically changes the value of the checkbox to CHECKED. I have the sql query like this:
select
apex_item.checkbox(1,"SW_CHECKED",DECODE("SW_CHECKED",1,'CHECKED',NULL)) " ",
apex_item.select_list_from_lov(2,"SW_STATUS",'F2010051_SET_STATUS','onChange="setCheckBox(this)"','NO') sTATUS,
from Fx1_v
I call a javascript function from the sql query, the call is ok, the problem is that i don't know how to pass the checkbox item to the function, and how it would work. I have tried calling the function with the parameter "this", but i believe it references the LOV, not the checkbox. I have also tried with setCheckBox(apex_application.g_f01) but it didn't work either. Any ideas, please?
Thanks in advance!