bobwillneverdie
New Member
Hi,<BR>iam using an image button inside a popup and closing the window on click of it. Iam passing "winow.close" as an attribute for the button from server side.<BR>Now the problem is , when the button is clicked(inside the popup), the same page gets opened again and when the button is clicked for the second time, the window closes.<BR>How do i resolve this. Iam using IE6.0<BR><BR>thanks in advance<BR><BR>kingI'm not seeing what you mean here.<BR><BR><input type="button" onclick="self.close()" /> should work perfectly. you appear to be describing an impossible situation. please clarifyThank you.<BR>I have a image button.<BR>Iam passing imgbutton.attributest.add("onclick","javascript:window.close();") on form load<BR>It turns up as <BR><input type=image onclick="javascript:window.close();"/> on the browser.<BR>When I click, the dialog gets closed, but the same page turns up in another window. when i click close button again, this window closes.<BR>The popup is a modal window <BR><BR>can you help<BR><BR>simhan<BR>drop the javascript: pseudo-url - you don't need it in event attributes.<BR><BR>imgbutton.attributest.add("onclick","self.close();")<BR><BR>and use self.close() as I demonstrated. perhaps you have some bizzarre window naming convention happening that I don't know about.<BR>Hi<BR>I tried, but no improvements.<BR>on click of close button which is inside the modal window, the same page appears in a normal window.<BR>When i click close again inside this norma window, the window closes.<BR>Could be a bug with modal window...<BR><BR>any thoughts<BR><BR>kingOK. here's the deal. do a view->source in the popup and post that code. perhaps there's extra code in there causing this issue.<BR><BR>also, if you can, put this code on a server somewhere so I can see it (cause I don't believe it)<BR><BR>I don't trust these ASP.NET controls. giving up control of your output to some developer in a building in redmond isn't my idea of heaven.