closing parent after pop up appears

S

sramruttun

hi

I open a pop up window using window.showModalDialog. How can I close the
parent window after the pop up appears ?
 
D

Daniel Bass

window.showModalDialog(...)
window.close();

will first launch your window, then close itself....
 
V

Vidar Petursson

Hi

You cant close the opener if you use a dialog until the dialog closes
use window.open instead.....

--
Best Regards
Vidar Petursson
==============================
Microsoft Internet Client & Controls MVP
==============================
 
S

sramruttun

thanks everyone for your replies
Daniel said:
window.showModalDialog(...)
window.close();
well I had tried this but it does not work..

Saravana is suggesting an article on how to close the POP UP WINDOW while I
want to close the parent (opener)

Vidur said that the opener can't be closed if you use a dialog until the
dialog closes
use window.open instead.....

I too thought that when showModalDialog is used, the parent can't be closed.
I'll need to use window.open.

But is there still a workaround to achieve it using showModalDialog?
 
S

sramruttun

ok Jerry
But what's the main difference between showModelessDialog and
showModalDialog ?
Both seem to be modal.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top