By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,786 Members | 2,241 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,786 IT Pros & Developers. It's quick & easy.

JSP page on closing the parent window the child windows should close automatically.

P: 34
Dear All,
How will we do in JSP page on closing the parent window the child windows should close automatically.

I will show my code

Please i will show you my code.

For HTML link
Expand|Select|Wrap|Line Numbers
  1. function closeWin()
  2. {
  3. if(window.applnreq && window.applnreq.open && !window.applnreq.closed)
  4. window.applnreq.close(); 
  5. }
  6. function showApplnFormWindow()
  7. {
  8.  
  9. strURL = '<%=ApplicationStatusHTMLPath%>';
  10. applnreq = window.open(strURL,"applnreq","height=450, width=650,scrollbars=yes,top=0,left=0,status=yes"); 
  11. applnreq.focus();
  12. }
For Pdf file i am using same code
Expand|Select|Wrap|Line Numbers
  1. function closeWin()
  2. {
  3. if(window.tradenpdfreq && window.tradenpdfreq .open && !window.tradenpdfreq .closed)
  4. window.tradenpdfreq .close(); 
  5. function showTradePDFWindow()
  6. {
  7.  
  8. strURL = '<%=TradePDFPath%>';
  9. tradenpdfreq = window.open(strURL,"tradenpdfreq","height=450, width=650,scrollbars=yes,top=0,left=0,status=yes"); 
  10. tradenpdfreq .focus();
  11. }
Sir for HTML it is working fine.But for PDF link it showing the error
"MEMBER NOT FOUND".

Please i request anybody to rectify my code in pdf link case so that
i should not face "MEMBER NOT FOUND".

Thanks and Regards
Sumanta Panda
Dec 24 '08 #1
Share this Question
Share on Google+
7 Replies


acoder
Expert Mod 15k+
P: 16,027
See http://bytes.com/groups/javascript/5...dfs-new-window (thread from newsgroup archives).
Dec 24 '08 #2

P: 34
According the link you have provided i did it.But still it is not working and showing error.


Could you please rectify my code which i have mentioned below.

Expand|Select|Wrap|Line Numbers
  1. function closeWin() 
  2. if(window.tradenpdfreq && window.tradenpdfreq .open && !window.tradenpdfreq .closed) 
  3. window.tradenpdfreq .close();  
  4. }  
  5. function showTradePDFWindow() 
  6.  
  7. strURL = '<%=TradePDFPath%>'; 
  8. tradenpdfreq = window.open(strURL,"tradenpdfreq","height=450, width=650,scrollbars=yes,top=0,left=0,status=yes");  
  9. tradenpdfreq .focus(); 
  10. }
Thanks a lot in Advance
Regards
Sumanta
Dec 25 '08 #3

acoder
Expert Mod 15k+
P: 16,027
Is this in all browsers or just a particular one?
Dec 29 '08 #4

P: 34
Dear Sir,
In my requirement this is viewed only for Internet Explorer with Internet Explorer 6.0 and above.

Kinly sir please look at my above code and please changes my code accordingly.

Thanks a lot in advance.

Regards
Sumanta Panda
Dec 30 '08 #5

acoder
Expert Mod 15k+
P: 16,027
Most likely this is an error that occurs in IE6, though I haven't tested the code with a PDF file. The PDF file is opened in Acrobat rather than the browser, so you lose control of the window. You could open a window and contain the PDF file in an iframe.
Dec 31 '08 #6

P: 34
Hi AcoderSir,
Thanks for your response.That Means sir,thier is no solution for my above requirement to solve the bug in IE6.0.
Kindly sir,Please advise me if any ultermative way is it possible to
solve this bog.

Thanks a lot in Advance.
Jan 2 '09 #7

acoder
Expert Mod 15k+
P: 16,027
As I said, I haven't tested, but you could try creating a HTML page with an iframe of full page size with the PDF file contained within it and open that page instead of opening the PDF file directly.
Jan 3 '09 #8

Post your reply

Sign in to post your reply or Sign up for a free account.