ASP Flush 方法

定义和用法

Flush 方法立即发送已缓存的 HTML 输出。

注释:假如 response.Buffer 为 false ,此方法会引起一个 run-time 错误

语法

  1. Response.Flush

实例

  1. <%
  2. Response.Buffer=true
  3. %>
  4. <html>
  5. <body>
  6. <p>I write some text, but I will control when the
  7. text will be sent to the browser.</p>
  8. <p>The text is not sent yet. I hold it back!</p>
  9. <p>OK, let it go!</p>
  10. <%
  11. Response.Flush
  12. %>
  13. </body>
  14. </html>

输出:

  1. I write some text, but I will control when the
  2. text will be sent to the browser.
  3.  
  4. The text is not sent yet. I hold it back!
  5.  
  6. OK, let it go!