Question

How I can change label(lblSaved), when UpdateProgress is running?My label update after UpdateProgress. I need, when UpdateProgress is starting run to do label(lblSaved) visible false.

<asp:UpdateProgress ID="uprogAutoSave" AssociatedUpdatePanelID="upnlAutoSave" runat="server">
  <ProgressTemplate>
     <asp:Literal runat="server" Text="<%$ Resources:AutoSave %>" /></ProgressTemplate>
 </asp:UpdateProgress> 

...

<asp:UpdatePanel ID="UpdatePanel1" RenderMode="Inline" runat="server">
   <Triggers>
        <asp:AsyncPostBackTrigger ControlID="TimerAutoSave" />
   </Triggers>
<ContentTemplate>
          <asp:Label ID="lblSaved" runat="server" />
</ContentTemplate>
                                        </asp:UpdatePanel>
Was it helpful?

Solution

You have to handel Ajax event from client-side using JavaScript or jQuery. You have to handle two Ajax event at client side.

  1. OnRequestStart
  2. OnResponseEnd

The first method call at same time your Ajax request start and the second one called when your ajax request become in complete state.
In this methods you have to handle your label, and this all is JavaScript/jQuery so I assume that you will not get any problem to manage the label.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top