Hai guys,
I want to modify the table values in tableview.But my modify operation not working.Could u guys help me.
Layout
<htmlb:tableView id = "tv1"
headerVisible = "true"
footerVisible = "false"
design = "ALTERNATING"
visibleRowCount = "5"
onRowSelection = "MyEventRowSelection"
selectionMode = "LINEEDIT"
table = "<%= itab %>" >
</htmlb:tableView>
<htmlb:button id = "button1"
design = "emphasized"
text = "Update"
onClick = "myClickHandler"
/>
oninput processing
DATA: tv TYPE REF TO CL_HTMLB_TABLEVIEW,
ind type i,
wa type yprojects.
DATA: event TYPE REF TO CL_HTMLB_EVENT.
event = CL_HTMLB_MANAGER=>get_event( runtime->server->request ).
IF event->name = 'button1' AND event->event_type = 'click'.
DATA: button_event TYPE REF TO CL_HTMLB_EVENT_BUTTON.
button_event ?= event.
tv ?= CL_HTMLB_MANAGER=>GET_DATA(
request = runtime->server->request
name = 'tableView'
id = 'tv2' ).
IF tv IS NOT INITIAL.
DATA: tv_data TYPE REF TO CL_HTMLB_EVENT_TABLEVIEW.
tv_data = tv->data.
ind = tv_data->selectedrowindex.
IF ind IS NOT INITIAL.
READ TABLE itab INDEX ind into wa.
modify yprojects from wa .
endif.
ENDIF.
ENDIF.