window not closing

G

gurvar

Hi,
I'm using window.close() command in a pop box (YesNo.aspx) embedded in a ASP
button clcik command.
Its a pop up confirmation for Yes or No. If either of them is clicked the
window seems to get enlarged instead of closing after it does its function.
How can I get to close the window when I click the buttons. I tried
selfclose, but doesn't work either.
Thanks in advance.
 
G

gurvar

I'm having a problem while closing cofirmation box
(Yes or No box).
when I choose either of them window.close seem to
be not executing, instead the page is getting fully
enlarged.Where am I going wrong?

Page_Load()
Button1.Attributes.Add("onclick", "window.returnValue
=document.getElementById('txtValue').value;window.close();")
Button2.Attributes.Add("onclick", "window.close();")
End Sub
 

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,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top