使UpdateProgress消失 [英] Make UpdateProgress disappear

查看:89
本文介绍了使UpdateProgress消失的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个执行一些excel自动化操作的按钮.我需要一个等待窗口,以便在代码运行时弹出.完成该代码后,我需要等待窗口消失,这就是我遇到的问题.
这是我的代码的一些摘要:

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:

<pre lang="xml"><asp:UpdatePanel ID="upPortfolioRpts" runat="server" UpdateMode="Conditional" ><br />
    <ContentTemplate><br />
        <div style="float:left;"><br />
            <asp:UpdateProgress ID="UpdProgWait" runat="server" AssociatedUpdatePanelID="upPortfolioRpts"><br />
                <ProgressTemplate><br />
        <img src="images/simple.gif" alt="progress"/><br />
                </ProgressTemplate><br />
            </asp:UpdateProgress><br />
        </div><br />
<br />
         <asp:Button ID="BtnCreateExcel" runat="server" Text="Merge Report(s) To Excel" OnClick="BtnCreateExcel_Onclick" Font-Size="X-Small"  OnClientClick="ShowProgress();"/><br />
<br />
        </div><br />
<br />
    </ContentTemplate><br />
<br />
        <Triggers><br />
            <asp:PostBackTrigger ControlID="BtnCreateExcel" /><br />
        </Triggers><br />
<br />
</asp:UpdatePanel></pre><br />
<code><br />
<br />
Javascript that shows the wait window<br />
<code>    function ShowProgress() {<br />
        document.getElementById(''<% Response.Write(UpdProgWait.ClientID); %>'').style.display = "inline";<br />
    } 



一切正常,除了Excel自动化完成后,我无法让等待窗口消失.有什么建议吗?



Everything works except I can''t get the wait window to disappear once the excel automation is completed. Any suggestions?

推荐答案

我看不到任何显示或隐藏它的代码,框架为您做到了吗?我会寻找框架给您的事件,并编写自己的脚本将其隐藏.
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.


这篇关于使UpdateProgress消失的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆