on 09-08-2011 3:05 PM
Hi All,
I got a requirement to make the selected field of Web Dynpro editable. The steps should be:
1. Point a table field(Table UI Element, not ALV).
2. click Edit button.
3. The field should become editable now, and the changes made should be reflected in the table.
Thanks
Gaurav
Hello Gaurav,
Are you talking about editing a row or a particular field? If your requirement is to edit a particular row then do the following
1. Create an attribute (say READ_ONLY ) of type boolean in the context node that was bound to the Table UI Element.
2. While populating the data for the Table's context node, set the value of the READ_ONLY attribute to abap_true
3. bind this attribute to the readOnly property of the Table Cell Editors
4. In the Action event handled of the button EDIT, write the code to reset the READ_ONLY flag
data lo_nd_table type ref to if_wd_context_node.
data lo_el_table type ref to if_wd_context_element.
lo_nd_table = wd_context->get_child_node( <TABLE's CONTEXT NODE NAME> ).
lo_el_table = lo_nd_Table->get_element( ).
lo_el_table->set_atttribute( name = 'READ_ONLY' value = abap_false ).
BR, Saravanan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
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.