Click here to Skip to main content
15,905,566 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I have a button that does some excel automation. I need a wait window to pop up while code is running. Once that code is done I need the wait window to disappear and that is where I have an issue.
Here is some summary of my code:
XML
<asp:UpdatePanel ID="upPortfolioRpts" runat="server" UpdateMode="Conditional" >
    <ContentTemplate>
        <div style="float:left;">
            <asp:UpdateProgress ID="UpdProgWait" runat="server" AssociatedUpdatePanelID="upPortfolioRpts">
                <ProgressTemplate>
        <img src="images/simple.gif" alt="progress"/>
                </ProgressTemplate>
            </asp:UpdateProgress>
        </div>

         <asp:Button ID="BtnCreateExcel" runat="server" Text="Merge Report(s) To Excel" OnClick="BtnCreateExcel_Onclick" Font-Size="X-Small"  OnClientClick="ShowProgress();"/>

        </div>

    </ContentTemplate>

        <Triggers>
            <asp:PostBackTrigger ControlID="BtnCreateExcel" />
        </Triggers>

</asp:UpdatePanel>

<br />
<br />
Javascript that shows the wait window<br />
<code>    function ShowProgress() {<br />
        document.getElementById('<% Response.Write(UpdProgWait.ClientID); %>').style.display = "inline";<br />
    } 


Everything works except I can't get the wait window to disappear once the excel automation is completed. Any suggestions?
Posted
Updated 10-Aug-11 9:38am
v3

1 solution

I don't see any code to show or hide it, does the framework do that for you ? I'd look for events that the framework gives you, and write my own script to hide it.
 
Share this answer
 
Comments
captain1210 22-Jul-11 8:01am    
sorry I forgot to add the javascript code...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900