on 12-11-2008 10:45 AM
Hi All,
we are showing a column as HTMLB link using iterator .
RENDER_CELL_START
when 'ACTION'.
if p_edit_mode is not initial.
data: bee_table type ref to cl_bsp_bee_table,
link type ref to cl_htmlb_link.
data: cell_id_del(20).
cell_id_del = p_cell_id.
create object bee_table.
link ?= cl_htmlb_link=>factory( id = p_cell_id
text = 'Modify Entries'
o n c l i c k = 'modify').
bee_table->add( element = link level = 1 ).
p_replacement_bee ?= bee_table.
in eventhandler OnInputProcessing , we are executing some ABAP code.
IF event IS NOT INITIAL AND event->event_name = htmlb_events=>link.
link_event ?= event.
CASE event->event_server_name.
WHEN 'modify'.
Some ABAP code.
flag = 'X' .
ENDCASE.
ENDIF.
In Layout we are checking the flag and calling a new popup window using window.open .
When the link is clicked for the first time , everything works fine.
But when we click the link second time , the popup window opens but , in the calling page (which contains the table view) all the internal tables are refreshed.
Application is stateful.
What can be the reason?
Thanks,
Anubhav
Hi anubhav
Once check in debugging mode whether you are clearing the internal table of data, else i guess this should not happen.
Regards
Vijay.M
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vijay,
I have checked , itabs are not refreshed anywhere and anyways in that case(itabs refreshing somewhere),they should be cleared when the link is clicked the first time only and not only the second time.
One more thing , i set a break point in OnInputProcessing at the event of that link click and before pressing F5 i checked the itabs and they are already refreshed.
Thanks a lot,
Anubhav
Hi,
The URL of window , which is called on click of the link.
w i nd ow.o p e n('tv_popup.htm?sap-sessioncmd=open&matcode='+matcode+'&end','mywindow','width=440,height=220,resizable=no');
can there be any problem in the url of called window?
Thanks All,
Anubhav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raja,
I debugged both pages the calling and the called, but as soon as i click the link for second time and OnInPutprocessing of calling page is triggered , i can see that all the internal tables are refreshed.
The code is as below:
I am using iterator to render the LINK column in tableview.
RENDER_CELL_START
when 'ACTION'.
if p_edit_mode is not initial.
data: bee_table type ref to cl_bsp_bee_table,
link type ref to cl_htmlb_link.
data: cell_id_del(20).
cell_id_del = p_cell_id.
create object bee_table.
link ?= cl_htmlb_link=>factory( id = p_cell_id
text = 'Modify Entries'
o n c l i ck = 'modify').
bee_table->add( element = link level = 1 ).
p_replacement_bee ?= bee_table.
endif.
In BSP Application->Calling page.
OnInputProcessing:
**Event handling for tableView LINK column.
IF event IS NOT INITIAL AND event->event_name = htmlb_events=>link.
link_event ?= event.
CASE event->event_server_name.
WHEN 'modify'.
flg_tv_popup = 'X' .
read table itab_materials into wa_materials index sy-index.
matcode = wa_materials-matnr.
ENDCASE.
ENDIF.
Layout:
<% if flg_tv_popup is not initial. %>
<s c r ipt t y p e='te x t / j av a script'>
v a r m a t code="< % = m a t code %>";
w i n d o w.op e n ( 't v _ p o pup. h t m?sap-sessioncmd=open&mat c od e= ' +m atc od e+'&e n d ',' m y wind o w ','w i d th= 4 40,h e i ght = 220, r e siz ab l e= n o');
</s c ript>
<% endif. %>
The called page contains a tableView and a save button which is used to update a ZDB table from the values entered in tableView.
It has nothing to do with the internal tables of calling page , so i guess it wont affect them.
Thanks a lot ,
Anubhav
Hi Raja,
i changed the called page URL from:
w i nd ow.o p e n('tv_popup.htm?sap-sessioncmd=open&matcode='+matcode+'&end','mywindow','width=440,height=220,resizable=no');
to
w i nd ow.o p e n('tv_popup.htm?matcode='+matcode+'&end','mywindow','width=440,height=220,resizable=no');
ie. removed SAP-SESSIONCMD = OPEN from the URL and its working fine as of now.
But i dont understand , how can the called page URL affect the calling page internal tables?
Thanks a lot for the help .
Regards,
Anubhav
Why don't you use "protectDoubleSubmit" tag to avoid the double click?
<xhtmlb:protectDoubleSubmit active="TRUE"/>
Raja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raja,
The issue is not that the link is clicked twice in succession , even if the user clicks the link after the first click is procssed completely , the itabs are refreshed and i am using protectdoublesubmit.
The problem is that the internal tables refreshed if the link is clicked more than once.
Thanks a lot,
Anubhav
Edited by: Anubhav Jain on Dec 12, 2008 5:56 AM
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.