on 09-28-2005 12:40 PM
Hi All,
I have a stateful BSP application. I have a tableview in that applications. I have the multiselect option in that table. Is there any way to clear the previous selected rows of the table. The table is getting new data without any problems but the previously selected line remain on the table Would appreciate if anyone could help me out as it is Urgent !!
Best Regards,
Sudhi
try calling
cl_htmlb_manager=>check_tableview_all_rows(
rowcount = rowcount
request = request
id = <tableviewid>
check = ' '
KEYTABLE = KEYTABLE
).
Regards
Raja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I guess u r asking abt the clearance of internal table rows.
Refresh your itab after declaration and clear it content at the end .
Hope this helps .
Regards,
J
Revert back if you still face problems.
Do Award points for helpful answers .
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sudhi,
You can follow up using this sample code. Here you can set a flag variable which is updated in onInputProcessing event.
Layout:
<htmlb:form>
<%
if flag is initial.
%>
<htmlb:tableView id = "tab1"
table = "<%= itab %>"
visibleRowCount = "8"
design = "ALTERNATING"
footerVisible = "TRUE"
selectionMode = "multiSelect"
keepSelectedRow = "true" >
</htmlb:tableView>
<%
endif.
%>
<%
if flag eq 1.
%>
<htmlb:tableView id = "tab2"
table = "<%= itab %>"
visibleRowCount = "8"
design = "ALTERNATING"
footerVisible = "TRUE"
selectionMode = "multiSelect"
keepSelectedRow = "true" >
</htmlb:tableView>
<%
clear flag.
%>
<%
endif.
%>
<htmlb:button id = "but01"
text = "Click"
onClick = "myEvent" />
</htmlb:form>
OnInputProcessing:
DATA: tv TYPE REF TO cl_htmlb_tableview.
DATA: event TYPE REF TO cl_htmlb_event.
event = cl_htmlb_manager=>get_event( runtime->server->request ).
IF event->id = 'but01' AND event->event_type = 'click'.
tv ?= cl_htmlb_manager=>get_data(
request = runtime->server->request
name = 'tableView'
id = 'tab1' ).
IF tv IS NOT INITIAL.
DATA: tv_data TYPE REF TO cl_htmlb_event_tableview.
tv_data = tv->data.
DATA : itab2 TYPE TABLE OF selectedrow,
ind TYPE selectedrow,
row_s TYPE zdi_so.
CALL METHOD tv_data->get_rows_selected
RECEIVING
selected_rows = itab2.
ENDIF.
IF itab2 IS NOT INITIAL.
DATA :rw LIKE LINE OF itab.
LOOP AT itab2 INTO ind.
flag = '1'.
DELETE itab INDEX ind-index.
ENDLOOP.
ENDIF.
ENDIF.
Hope this helps,
Regards,
Ravikiran.
Message was edited by: Ravikiran C
User | Count |
---|---|
85 | |
10 | |
9 | |
9 | |
6 | |
6 | |
6 | |
5 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.