cancel
Showing results for 
Search instead for 
Did you mean: 

problem in closing the session.

Former Member
0 Kudos
178

Hi,

I have problems in closing the sessions of the application I wrote.

The is the method that I have used in closing the session on event ONUNLOAD.


var url="";
<%
  if runtime->session_manager->is_running = 0.
%>
<%
  CLASS cl_bsp_login_application DEFINITION LOAD.
%>
var url  = "<%= CL_BSP_LOGIN_APPLICATION=>GET_SESSIONEXIT_URL( page = page )%>";

<%
  IF do_not_delete_sso2_cookie IS NOT INITIAL.
%>
  url += "&bsp_do_not_delete_sso2_cookie=X";
<%
  ENDIF.
%>

var prop = 'height=100,width=400,top=-2000,left=-2000';
var out = window.open(url,'_blank',prop);
<%
  endif.
%>

When I close the window a popup is opened and says that loging off....

But when I open the same url with the link of my home page,

the same page is opened with all the data the same when I closed the window.

Could u please tell me where In my method I am going wrong..

Regards,

venkatesh.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

If u r in a statefull application then session data is stored in coookie whose name is value of "sap-contextid".

Check the following link :

http://help.sap.com/saphelp_erp2004/helpdata/en/1b/f9b53a364e0e5fe10000000a11405a/frameset.htm

Hope it'll help u.

Thanks & Regards

Ankur

Former Member
0 Kudos

Hi Ankur,

I have tried out the same way.

But when the window is closed the instance is not deleted.

The same instance is showed when I open the window with some variable cleared like the selected index of the tableview,But there is data in the tableview.

regards,

Venkatesh

Former Member
0 Kudos

Hi ,

I guess may be navigation->exit( ) method would be useful to you.

for full information please visit the following link :

http://help.sap.com/saphelp_erp2004/helpdata/en/c2/231779c53011d4990400508b6b8b11/frameset.htm

Moreover just before closing session u can make ur application stateless by runtime->keep_context = 0.

This might be of use to u.

Hope it'll help u.

Thanks & Regards,

Ankur