on 01-30-2009 2:07 PM
Hi,
I have 2 radio buttons and i have to disappear some UI elements ( label and inputfields ) if i select either of these buttons.
Thanks in advance
Ganesh
Edited by: ganesh ram on Jan 30, 2009 7:38 PM
Hi Ganesh,
First bind the visibility property of those UI elements which you want to disappear to a context on WDUI_VISIBILITY type (set the default property of the context as '02' ). Now you have two radio buttons. In the ONACTION method of the radio button just set the context (binded to visibility property) of those UI elements which you want to disappear to '01'. This will make them disappear.
I hope it helps
Regards
Arjun
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
Check the sample Wedbynpro Component WDR_TEST_events . This is having the complete UI element functionalities in WDA.
Regards ,
Kalpana A .
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI Ganesh,
Say if there are two radio buttons payroll and fi, if any one of them is selected then the other should be disabled.
first bind the two radio button ui elements for payroll and fi to attribute say zpayroll_chk and zfi_chk of type wdy_boolean respectively.
For payroll radio buttons create a toggle event onpayrollselect and write the following code,
data lo_nd_screen_valid type ref to if_wd_context_node. *screen_valid is the name of the node *
data lo_el_screen_valid type ref to if_wd_context_element.
data ls_screen_valid type wd_this->element_screen_valid.
data lv_zpayroll_chk like ls_screen_valid-zpayroll_chk. zpayroll_chk is the name of the attribute inside the node screen_valid.
navigate from <context> to <screen_valid> via lead selection
lo_nd_screen_valid = wd_context->get_child_node( name = wd_this->wdctx_screen_valid ).
get element via lead selection
lo_el_screen_valid = lo_nd_screen_valid->get_element( ).
get single attribute
lo_el_screen_valid->get_attribute(
exporting
name = `zpayroll_chk`
importing
value = lv_zpayroll_chk ).
if lv_zpayroll_chk is not initial.
lo_el_screen_valid->set_attribute(
exporting
name = `zfi_chk`
value = ' ' ).
endif.
For fi radio button create a toggle event onfiselect and write the following code,
data lo_nd_screen_valid type ref to if_wd_context_node. * screen_valid is the name of the node*
data lo_el_screen_valid type ref to if_wd_context_element.
data ls_screen_valid type wd_this->element_screen_valid.
data lv_zfi_chk like ls_screen_valid-zfi_chk. zfi_chk is the name of the attribute inside the node screen_valid.
navigate from <context> to <screen_valid> via lead selection
lo_nd_screen_valid = wd_context->get_child_node( name = wd_this->wdctx_screen_valid ).
get element via lead selection
lo_el_screen_valid = lo_nd_screen_valid->get_element( ).
get single attribute
lo_el_screen_valid->get_attribute(
exporting
name = ``zfi_chk`
importing
value = lv_zfi_chk ).
if lv_zfi_chk is not initial.
lo_el_screen_valid->set_attribute(
exporting
name = `zpayroll_chk`
value = ' ' ).
endif.
Thanks,
Rajkumar.S
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.