After installing .NET Framework 2.0 sp1, PostRequestHandlerExecuteevent never fires again!

X

Xiuming

Dear All:

I encount a problem after installing .NET Framework 2.0 sp1, anyone
can help?
I ever wrote a HTTP Module and provided a few event handler, including
PostRequestHandlerExecute event. I deployed this module in WebApp
which not only including WebPages but also some WebServices. Before I
install latest .NET Framework 2.0 sp1, all things are fine, but after
that, I found that when an aspx resource is visited the event never
fires again, but when an asmx resource is visited, the event DOES
fire!.

I checked my codes and found that if I call response.End() method in
page processing, the event stops working, but before installing .NET
Framework 2.0 sp1 this never happened.

Has Microsoft engineers changed the ASP.NET processing rules? or is
this a bug?

Below is some relevent codes:

#region IHttpModule Members

public void Dispose()
{
}

public void Init(HttpApplication context)
{
this._customErrors = GetWebCustomErrorsSection(context);
context.BeginRequest += new
EventHandler(context_BeginRequest);
context.AuthenticateRequest += new
EventHandler(context_AuthenticateRequest);
context.AuthorizeRequest += new
EventHandler(context_AuthorizeRequest);
context.PreRequestHandlerExecute +=new
EventHandler(context_PreRequestHandlerExecute);
context.PostRequestHandlerExecute += new
EventHandler(context_PostRequestHandlerExecute);
context.PreSendRequestHeaders += new
EventHandler(context_PreSendRequestHeaders);
}
#endregion

void context_PostRequestHandlerExecute(object sender,
EventArgs e)
{
HttpApplication app = sender as HttpApplication;
app.Response.Filter = new AuthFilter(app.Response.Filter,
app.Response, this);
}
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top