请问当一个页面处理比较长时,怎么显示一个动画,当页面处理完成时自动转回页面是不是要用到线程啊?
解决方案 »
- 关于检测到有潜在危险的 Request.Form 值的问题
- 对于数据导入excel 文字乱码的问题有没有好点的解决方案?
- SQL语句如何写
- ajax可以提交到本页后台吗
- 如何去掉TextBox的边框(在线等)
- 在windows窗体下能调用存储过程么?
- VS2005,b/s的程序,我想实现:学生一开机就弹出一个IE窗口,他们可以在IE窗口输入一些信息然后提交,怎么实现?
- 我做一个软件下载,如何屏蔽软件的实际路径?
- asp.net cs端 防止未登陆直接访问 本人是学java的 而且一般做的都是web
- 请问NWGS支持98吗
- 请各位高手帮个忙读个代码
- 消息框Messagebox 在前面定义的类型或命名空间是什么?(在线等!在线等)
接分来了 给以后帮助我的朋友 呵呵 \\\|///
\\ .-.- //
. ( .@.@ )
+-------oOOo-----(_)-----oOOo---------+
| |
| 感谢无私帮助他人的朋友 |
| |
+---------------------Oooo------------+
<div id="doing" runat="server" style="Z-INDEX: 12000; LEFT: 0px; VISIBILITY: hidden; WIDTH: 100%; POSITION: absolute; TOP: 300px; HEIGHT: 100%">
<table width="100%" height="100%">
<tr align="center" valign="middle">
<td>
<table width="169" class="font3" height="62" bgcolor="#6699ff" style="FILTER: Alpha(Opacity=75); WIDTH: 169px; HEIGHT: 62px">
<tr align="center" valign="middle">
<td>页面提交中,请等待<br>
Please wait
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
pageload里面这么写:this.Button1.Attributes.Add("onclick","document.getElementById('doing').style.visibility='visible';");
,等操作结束重定向了后页面重新加载一次,这个层也就消失了
http://community.csdn.net/Expert/TopicView.asp?id=4357863
对于加载时间比较长的ASP.NET页面,我们可以在客户端浏览器中显示进度条来显示页面正在装载。下面就是具体的实现过程:新建项目,名字为WebPortal,在项目类型中选择Visual C#项目或者Visual Basic项目都可;
在模板类型中选择ASP.NET Web应用程序;
位置里输入:http://localhost/WebPortal;
添加新项:名字为ShowProgress的Web窗体。
在您的Web窗体ShowProgress.aspx上添加任何其他的Web服务器控件。
在ShowProgress.aspx上单击右键,点“查看代码”,在最上面输入:
Visual C# .NET代码
using System.Threading;Visual Basic .NET代码
Imports System.Threading在Page_Load事件里输入: Visual C# .NET代码
Response.Write("<div id='mydiv' >");
Response.Write("_");
Response.Write("</div>");
Response.Write("<script>mydiv.innerText = '';</script>");
Response.Write("<script language=javascript>;");
Response.Write("var dots = 0;var dotmax = 10;function ShowWait()");
Response.Write("{var output; output = '正在装载页面';dots++;if(dots>=dotmax)dots=1;");
Response.Write("for(var x = 0;x < dots;x++){output += '·';}mydiv.innerText = output;}");
Response.Write("function StartShowWait(){mydiv.style.visibility = 'visible'; ");
Response.Write("window.setInterval('ShowWait()',1000);}");
Response.Write("function HideWait(){mydiv.style.visibility = 'hidden';");
Response.Write("window.clearInterval();}");
Response.Write("StartShowWait();</script>");
Response.Flush();
Thread.Sleep(10000);Visual Basic .NET代码
Response.Write("<div id='mydiv' >")
Response.Write("_")
Response.Write("</div>")
Response.Write("<script>mydiv.innerText = '';</script>")
Response.Write("<script language=javascript>;")
Response.Write("var dots = 0;var dotmax = 10;function ShowWait()")
Response.Write("{var output; output = '正在装载页面';dots++;if(dots>=dotmax)dots=1;")
Response.Write("for(var x = 0;x < dots;x++){output += '·';}mydiv.innerText = output;}")
Response.Write("function StartShowWait(){mydiv.style.visibility = 'visible'; ")
Response.Write("window.setInterval('ShowWait()',1000);}")
Response.Write("function HideWait(){mydiv.style.visibility='hidden';")
Response.Write("window.clearInterval();}")
Response.Write("StartShowWait();</script>")
Response.Flush()
Thread.Sleep(10000)在ShowProgress.aspx窗体的html的中输入:
<script>
HideWait();
</script>点在浏览器中查看即可。 大家看看有没有更好的方法
1.是英文的。
2.版本中包含的SQL是express版而不是开发版。
3.楼上提供的vs2005链接正确。
请问一下楼上的,这两种的别是不是回调产生Postback事件而回访不产生?
公司的所有项目都是用VS2003的,平时少不了它,但是又想装个VS2005来玩……