Response.Flush

Discussion in 'ASP General' started by Jason, Sep 1, 2004.

  1. Jason

    Jason Guest

    I am using response.flush in order to display "Please
    wait" message. The problem is that it takes about 15 to
    20 seconds for the message to appear. How can I make
    this appear as soon as the user accesses the page. I am
    using response.buffer = true as well.

    I have about five include files on the page.


    <body bgcolor="#FFFFFF" text="#000000">
    <script>
    <!--
    if (document.all)
    {
    document.write("<span id=w>");
    document.write("<table width=100%>");
    document.write("<tr><td>&nbsp;</td></tr>")
    document.write("<tr><td
    align=center><b>Please wait while we compile your
    report...</b></td></tr>")
    document.write("<tr><td align=center><img
    src=images/wait.gif></td></tr>")
    document.write("</table>");
    document.write("</span>");
    }
    //-->
    </script>
    <% Response.Flush() %>
     
    Jason, Sep 1, 2004
    #1
    1. Advertising

  2. Jason

    Mark Schupp Guest

    Do the include files contain code that executes before the client-side
    script block is written out?

    --
    Mark Schupp
    Head of Development
    Integrity eLearning
    www.ielearning.com


    "Jason" <> wrote in message
    news:44c301c49044$0e0aa110$...
    > I am using response.flush in order to display "Please
    > wait" message. The problem is that it takes about 15 to
    > 20 seconds for the message to appear. How can I make
    > this appear as soon as the user accesses the page. I am
    > using response.buffer = true as well.
    >
    > I have about five include files on the page.
    >
    >
    > <body bgcolor="#FFFFFF" text="#000000">
    > <script>
    > <!--
    > if (document.all)
    > {
    > document.write("<span id=w>");
    > document.write("<table width=100%>");
    > document.write("<tr><td>&nbsp;</td></tr>")
    > document.write("<tr><td
    > align=center><b>Please wait while we compile your
    > report...</b></td></tr>")
    > document.write("<tr><td align=center><img
    > src=images/wait.gif></td></tr>")
    > document.write("</table>");
    > document.write("</span>");
    > }
    > //-->
    > </script>
    > <% Response.Flush() %>
    >
     
    Mark Schupp, Sep 1, 2004
    #2
    1. Advertising

  3. Jason

    Jason Guest

    I found the problem. I put the "Please wait text at the
    top of my page before my include files.

    >-----Original Message-----
    >Do the include files contain code that executes before

    the client-side
    >script block is written out?
    >
    >--
    >Mark Schupp
    >Head of Development
    >Integrity eLearning
    >www.ielearning.com
    >
    >
    >"Jason" <> wrote in

    message
    >news:44c301c49044$0e0aa110$...
    >> I am using response.flush in order to display "Please
    >> wait" message. The problem is that it takes about 15

    to
    >> 20 seconds for the message to appear. How can I make
    >> this appear as soon as the user accesses the page. I

    am
    >> using response.buffer = true as well.
    >>
    >> I have about five include files on the page.
    >>
    >>
    >> <body bgcolor="#FFFFFF" text="#000000">
    >> <script>
    >> <!--
    >> if (document.all)
    >> {
    >> document.write("<span id=w>");
    >> document.write("<table width=100%>");
    >> document.write("<tr><td>&nbsp;</td></tr>")
    >> document.write("<tr><td
    >> align=center><b>Please wait while we compile your
    >> report...</b></td></tr>")
    >> document.write("<tr><td align=center><img
    >> src=images/wait.gif></td></tr>")
    >> document.write("</table>");
    >> document.write("</span>");
    >> }
    >> //-->
    >> </script>
    >> <% Response.Flush() %>
    >>

    >
    >
    >.
    >
     
    Jason, Sep 1, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Marina

    Re: Response.Flush() in code-behind

    Marina, Jul 1, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    469
    William F. Robertson, Jr.
    Jul 1, 2003
  2. William F. Robertson, Jr.

    Re: Response.Flush() does not work

    William F. Robertson, Jr., Aug 5, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    523
    William F. Robertson, Jr.
    Aug 5, 2003
  3. Glen Wilkin via DotNetMonster.com

    Response.Redirect after Response.Flush

    Glen Wilkin via DotNetMonster.com, Apr 15, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    7,091
  4. Replies:
    5
    Views:
    605
    =?ISO-8859-1?Q?G=F6ran_Andersson?=
    Jun 12, 2007
  5. Richard N.

    Response.Flush / Response.Redirect

    Richard N., Oct 18, 2003, in forum: ASP General
    Replies:
    1
    Views:
    220
    Tom B
    Oct 19, 2003
Loading...

Share This Page