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

hide child window

 
Nimish Patel
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
in parent window i have created one frame( frame1).
and child window have a one submit button. when submit button press action is exucuted and output also display in frame1.
but i cannot hide child window. it still displays on top.
i try "self.close()" but it is not working with action and submit.
what should i do ? so i can hide child window and exucute action & do submit.
i have given code following but it dont hide child window.it is called by
child window submit button.
document.searchForm.target="frame1";
document.searchForm.action="/SIPProfile/View.do?userID="+xx;
document.searchForm.submit();
thanks in anticipation.
NIMISH PATEL.US
 
Niki Nono
Ranch Hand
Posts: 256
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what happens when you do a window.close() after the submit line?
It should work. I had done that in one of the projects. What exactly happens when you write the .close() line and click submit?
 
Nimish Patel
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks niki for reply. i try but it is not working.
action & submit process is done and also output display in frame1.
but child window still open.
function submit()
{
document.searchForm.target="frame1";
document.searchForm.action="/SIPProfile/View.do?userID="+xx;
document.searchForm.submit();
window.close();
}
thanks,
Nimish
 
Niki Nono
Ranch Hand
Posts: 256
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
just guessing but try calling window.close() before you submit the form.
 
Nimish Patel
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks niki...
now it is working.
and have a good future.
bye bye.
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you close the window before the submission, I have a feeling that your submission is never sent. You better check that....

Eric
 
Nimish Patel
Ranch Hand
Posts: 84
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi eric,
i have given the code.it is working.IT invokes view action and output also display in frame1(another JSP). so submit()is executed.

function submit()
{
document.searchForm.target="frame1";
document.searchForm.action="/SIPProfile/View.do?userID="+xx;
window.close();
document.searchForm.submit();
}

thanks for help,
nimish
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic