按道理该一行行显示啊,为啥我的还是等会然后全部刷新出来
<%@ WebHandler Language="C#" Class="Responseflush" %>
using System;
using System.Web;
public class Responseflush : IHttpHandler {
public void ProcessRequest (HttpContext context) {
context.Response.ContentType = "text/html";
for(int i = 0; i < 20; i++)
{
System.Threading.Thread.Sleep(500);
context.Response.Write("第" + i + "步执行完成!</br>");
context.Response.Flush();
}
}
public bool IsReusable {
get {
return false;
}
}
}