HttpHandler Progress Indicator

Discussion in 'ASP .Net' started by Dale Ragan via .NET 247, Aug 6, 2004.

  1. (Type your message here)

    --------------------------------
    From: Dale Ragan

    I am running into a problem with an HttpHandler that I have builtto show a progress image on the page getting processed. I amusing Response.Flush and as you know you cannot have aResponse.Redirect after you have flushed the buffered content tothe client. You get the cannot modify cookies after the headerhas been sent exception. I know of some ways to correct this bygoing into the individual pages and taking out theResponse.Redirect instances and replacing them with anothermeans of redirecting the user. The question I have is, if thereis a way to capture the Response.Redirect in my HttpHandler andhandle it there instead of recoding every page that will need aprogress indicator.

    Thanks in advance for any input.

    Dale

    -----------------------
    Posted by a user from .NET 247 (http://www.dotnet247.com/)

    <Id>T5aQ140aZUeihMuKIgZgCA==</Id>
     
    Dale Ragan via .NET 247, Aug 6, 2004
    #1
    1. Advertising

  2. Dale,

    I don't think that would work any way you try this because a Redirect()
    requires that HTTP Headers are sent to the client. If you're flushing and
    you have previously created output the headers have already gone to the
    client.

    One thing you could do is dynamically add some JavaScript to the page when
    you are ready to rediect. The script can change the location of the current
    page. IOW, you generate some additional HTML that has this script code
    inline with the body of the page which will then run as it gets to the
    browser...

    +++ Rick ---

    --

    Rick Strahl
    West Wind Technologies
    http://www.west-wind.com/
    http://www.west-wind.com/weblog/
    http://www.west-wind.com/wwThreads/
    ----------------------------------
    Making waves on the Web


    "Dale Ragan via .NET 247" <> wrote in message
    news:...
    (Type your message here)

    --------------------------------
    From: Dale Ragan

    I am running into a problem with an HttpHandler that I have built to show a
    progress image on the page getting processed. I am using Response.Flush and
    as you know you cannot have a Response.Redirect after you have flushed the
    buffered content to the client. You get the cannot modify cookies after the
    header has been sent exception. I know of some ways to correct this by
    going into the individual pages and taking out the Response.Redirect
    instances and replacing them with another means of redirecting the user.
    The question I have is, if there is a way to capture the Response.Redirect
    in my HttpHandler and handle it there instead of recoding every page that
    will need a progress indicator.

    Thanks in advance for any input.

    Dale

    -----------------------
    Posted by a user from .NET 247 (http://www.dotnet247.com/)

    <Id>T5aQ140aZUeihMuKIgZgCA==</Id>
     
    Rick Strahl [MVP], Aug 6, 2004
    #2
    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. Koen Janssens

    terminal progress indicator

    Koen Janssens, Nov 25, 2003, in forum: C++
    Replies:
    10
    Views:
    760
    Peter Koch Larsen
    Nov 29, 2003
  2. =?Utf-8?B?Q2hyaXM=?=

    Move progress indicator in atlas

    =?Utf-8?B?Q2hyaXM=?=, Jun 10, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    592
  3. Marko Vuksanovic

    File Upload Progress Indicator

    Marko Vuksanovic, Jun 22, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    567
  4. Marko Vuksanovic

    File Upload Progress Indicator ?

    Marko Vuksanovic, Jun 23, 2006, in forum: ASP .Net
    Replies:
    6
    Views:
    10,959
  5. Marko Vuksanovic

    Implementing upload progress indicator question

    Marko Vuksanovic, Jun 24, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    694
Loading...

Share This Page