I have a single UpdateProgress control in my UpdatePanel. In this UpdatePanel I have a MultiView. This MultiView has many buttons to navigate the different Views.
What I am trying to do is only show the UpdateProgress animation when a specific button is clicked. All other buttons should hide/disable the UpdateProgress control. I am attempting this through jQuery. I am open to any method though.
This is my current code:
function hideProgress() {
$('#<%= UpdateProgress.ClientID %>').hide();
//console.log('hello');
return false;
}
Here is one of the buttons:
<asp:Button ID="btnCancel" runat="server" Text="Cancel" OnClick="btnCancel_Click" OnClientClick="hideProgress()" />
I know I am getting into my function because I get my log message. There are no errors, it just doesn’t work.
Can someone show me how I would accomplish this?
Thanks!
Try the solution proposed here: https://stackoverflow.com/a/6301744/1071574.
In a nutshell, the idea is to associate the
UpdateProgresscontrol with a “dummy” (i.e. inexistent)UpdatePanelwhenever you want to disable it, based on the control that generated the async postback. This will cause it never to show (since the onlyUpdatePanelit is supposed to work with doesn’t exist).