File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

While closing window wants to submit into servlet

 
kapildev ganeshan
Greenhorn
Posts: 17
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I wants to remove the session attributes while closing the window.
from the script if I give like this

function closeWindow()
{
alert("Closing the window");
document.formc.reqType.value="closeConn";
document.formc.submit();
window.close();
}

from the servlet I am getting the exception as weblogic.utils.NestedRuntimeException

so any tips/help would be greatly appreciated
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Discussed multiple times in the past week:

http://www.coderanch.com/t/118024/HTML-JavaScript/submit-form-when-closing-browser

Eric
 
kapildev ganeshan
Greenhorn
Posts: 17
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Thanks for the reply. I have a button "Cancel" While I am pressiong the cancel it has submitted in to the servlet. But I got the exception as " weblogic.utils.NestedRuntimeException". If I remove the window.close();
from the function then its working fine.May I know the reason for this. Also I wants to close the window in that same time.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic