I have a page with a user control which gets some data updated via a modal popup. Upon clicking “ok” on the modal popup – the new data is being written to the database – but the base page doesnt “reload” to show the updated data. How do I get that to happen?
Share
1) Don’t set the OKControlID property on the ModalPopupExtender.
2) In your Page_Load, set
OkButton.OnClientClick = string.Format("$find('{0}').hide();", modalPopupExtender1.ClientID);Explanation:
Setting the OkControlID stops the button from posting back. Instead, manually use javascript to hide the extender, which will allow the button to post the form.