I am new to Ajax. I have designed an ajax web page and inserted a button(btnASP). On clicking this button I am displaying modal pop up. Till here it is working fine. Now I have a cancel button within modal pop up. if I click cancel button the pop up is closing.
Now my problem is if I click the btnASP again modal pop up is not displayed. A black screen of modal popup size is displayed. below is the code written for extender. Please help.
You'll see if you have ModalPopup associated with AnimationExtender. You may refer to this post that use AnimationExtender to run a script to open the ModalPopup, see if it helps,
http://forums.asp.net/t/1080503.aspx/1
sun_shen
Member
103 Points
109 Posts
Issue with closing Modal popup
Aug 14, 2012 08:00 AM|LINK
Hi All,
I am new to Ajax. I have designed an ajax web page and inserted a button(btnASP). On clicking this button I am displaying modal pop up. Till here it is working fine. Now I have a cancel button within modal pop up. if I click cancel button the pop up is closing. Now my problem is if I click the btnASP again modal pop up is not displayed. A black screen of modal popup size is displayed. below is the code written for extender. Please help.
<asp:ModalPopupExtender X="275" Y="75" ID="panel1_ModalPopupExtender1" TargetControlID="btnASPButton"
runat="server" Enabled="True" PopupControlID="panel1" CancelControlID="btnCancel"
DropShadow="true" BackgroundCssClass="modalBackground" BehaviorID="panel1_ModalPopupExtender1">
</asp:ModalPopupExtender>
athar_techsa...
Member
554 Points
316 Posts
Re: Issue with closing Modal popup
Aug 14, 2012 08:43 AM|LINK
hi
Can you please show the code in btnASPButton event?
I think you might me missing UpdatePanel1.Update(); in the btnASPButton event.
Feel free to ask if you any doubts
sun_shen
Member
103 Points
109 Posts
Re: Issue with closing Modal popup
Aug 14, 2012 09:37 AM|LINK
Hi Athar,
there is nothing written in btnASPButton event. Since you had mentioned about missing UpdatePanel1.Update(); I added it and tested. But no luck.
btnASPButton is just used to open the modal popup.
amit.jain
Star
11225 Points
1815 Posts
Re: Issue with closing Modal popup
Aug 14, 2012 06:45 PM|LINK
refer http://csharpdotnetfreak.blogspot.com/2011/03/ajax-modalpopupextender-example-aspnet.html
http://csharpdotnetfreak.blogspot.com/2012/07/edit-update-gridview-modalpopupextender.html
amiT jaiN
ASP.NET C# VB Articles And Code Examples
chetan.sarod...
All-Star
65619 Points
11118 Posts
Re: Issue with closing Modal popup
Aug 15, 2012 04:45 AM|LINK
http://mattberseth.com/blog/2007/08/how_to_dismiss_a_modalpopup_us.html
http://mattberseth.com/blog/2008/05/bug_bashbuttoncausesvalidation.html
Senior Software Engineer,
Approva Systems Pvt Ltd, Pune, India.
sun_shen
Member
103 Points
109 Posts
Re: Issue with closing Modal popup
Aug 16, 2012 03:47 AM|LINK
Hi All,
I had animation extender in my code. I removed that and it is working fine now. But not sure why it was not working with animation extender.
Regards,
BU XI - MSFT
All-Star
22367 Points
2704 Posts
Microsoft
Re: Issue with closing Modal popup
Aug 16, 2012 05:37 AM|LINK
Hello
You'll see if you have ModalPopup associated with AnimationExtender. You may refer to this post that use AnimationExtender to run a script to open the ModalPopup, see if it helps, http://forums.asp.net/t/1080503.aspx/1
If you have any feedback about my replies, please contact msdnmg@microsoft.com.
Microsoft One Code Framework