on 04-07-2009 6:38 AM
Hi expert,
I want to dynamic radio button by web dynpro abap .
Kindly give me a soulation ASAP.
Thanks and regard's
Vikash
hi,
method wddomodifyview .
if first_time eq abap_true.
data: LR_CONTAINER type ref to CL_WD_UIELEMENT_CONTAINER,
LR_RADIOBUTTON1 type ref to CL_WD_RADIOBUTTON,
LR_RADIOBUTTON2 type ref to CL_WD_RADIOBUTTON,
LR_FLOW_DATA type ref to CL_WD_FLOW_DATA.
" bind text property will give TEXT that appears next to Radio Button
CALL METHOD cl_wd_radiobutton=>new_radiobutton
EXPORTING
bind_selected_key = '01'
BIND_TEXT = 'saurav'
receiving
control = LR_RADIOBUTTON1.
" bind text property will give TEXT that appears next to Radio Button
CALL METHOD cl_wd_radiobutton=>new_radiobutton
EXPORTING
bind_selected_key = '02'
BIND_TEXT = 'mago'
receiving
control = LR_RADIOBUTTON2.
LR_FLOW_DATA = CL_WD_FLOW_DATA=>NEW_FLOW_DATA( element = LR_RADIOBUTTON1 ).
LR_FLOW_DATA = CL_WD_FLOW_DATA=>NEW_FLOW_DATA( element = LR_RADIOBUTTON2 ).
LR_CONTAINER ?= view->GET_ELEMENT( 'ROOTUIELEMENTCONTAINER' ).
LR_CONTAINER->ADD_CHILD( LR_RADIOBUTTON1 ).
LR_CONTAINER->ADD_CHILD( LR_RADIOBUTTON2 ).
endif.
endmethod.
Thanx.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Please use radio button group class
Best Regards
Ravi Golla
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vikash,
Refer these blogs on dynamic programming:
/people/thomas.szcs/blog/2005/12/28/dynamic-programming-in-web-dynpro-abap--introduction-and-part-i-understanding-ui-elements
/people/thomas.szcs/blog/2006/01/03/dynamic-programming-in-web-dynpro-abap--part-ii-handling-viewelements
/people/thomas.szcs/blog/2006/02/22/dynamic-programming-in-web-dynpro-abap--part-iii-aggregations-and-ddic-binding-of-viewelements
alos have a look at the code provided by Prashant in this thread:
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.
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.