Response.Write("<TABLE style='Z-INDEX: 109; LEFT: 120px; WIDTH: 590px; POSITION: absolute; TOP: 364px; HEIGHT: 24px' cellSpacing='1' cellPadding='1' width='590' border='0'><TR><TD>&nbsp;<form name=loading> <p align=center> <font color='#800000' size='2'>数据备份中,请稍后</font><font color='#800000' size='2' face='Arial'>...</font>");
Response.Write("<input type=text name=chart size=46 style='font-family:Arial; font-weight:bolder; color:#ff0000; background-color:#fef4d9; padding:0px; border-style:none;'>");
Response.Write("<input type=text name=percent size=47 style='color:#ff00ff; text-align:center; border-width:medium; border-style:none;'> ");
Response.Write("<script language=javascript>");
Response.Write("var bar=0;");
Response.Write("var line='||';");
Response.Write("var amount='||';");
Response.Write("count();");
Response.Write("function count(){");
Response.Write("bar=bar+2;");
Response.Write("amount =amount + line;");
Response.Write("document.loading.chart.value=amount;");
Response.Write("document.loading.percent.value=bar+'%';");
Response.Write("if (bar<99){");
Response.Write("setTimeout('count()',100);}");
Response.Write("else{");
Response.Write("alert('恭喜您,数据备份成功!');}");
Response.Write("}</script></TD></TR></TABLE>");

解决方案 »

  1.   

    <title>loadpage</title>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312"><style type="text/css"><!--.unnamed1 {  background-color: #000000}--></style></head><body><table border=0 cellpadding=0 cellspacing=0 width="100%" height="100%"><tr> <form name=loading>      <td align=center>         <p align="center">&nbsp;</p>        <p align="center"><font color="#00FF00" size="2"></font></p>        <p> 
              <input type=text name=chart size=46 style="font-family:Arial; font-weight:bolder; color:#00FF00; background-color:black; padding:0px; border-style:none;">
              <br>
              <br>
              <input type=text name=percent size=46 style="font-family:Arial; color:#00FF00; text-align:center; border-width:medium; border-style:none;" class="unnamed1">
              <br>
              <br>
              <font color="#00FF00" size="2" > 
              <script>
    var bar = 0 var line = "||" var amount ="||" count() function count(){ bar= bar+2 amount =amount + line document.loading.chart.value=amount document.loading.percent.value=bar+"%" if (bar<99) 
    {
    setTimeout("count()",100);
    } else 
    {
    alert("载入完毕")
    window.location = "http://www.csdn.net";
    } }</script>
              
              <noscript></noscript></font></p>
            
                      </td><!--//-->
    </form></tr></table></body></html> 
      

  2.   

    不对啊,上面两位给出的只是显示这个loading条而已啊,我要的是在目标page被load过程中,显示这个,表示友好的,进度条晚了应该立即看到页面的~~~~
      

  3.   

    我自己找到了一个办法:
    private void Page_Load(object sender, System.EventArgs e)
    {
    Response.Buffer = true;
    Response.Write("<div id='loading'>Loading...</div>");
             Response.Flush(); DoThings(); Response.Flush();
    }
      

  4.   

    请问: jie1999(杰)
        结果Response.Write("<div id='loading'>Loading...</div>");看不到效果。