Trace Does Not Appear to Work on Global.asax

M

Mark

I am testing the tracing function of ASP.NET 2.0 and have included the
following code in the the global.asax file:

protected void Application_AcquireRequestState(object sender,
EventArgs e)
{

HttpContext.Current.Trace.Warn("AcquireRequestState called from
" + sender.ToString());
HttpContext.Current.Trace.Write("AcquireRequestState called
from " + sender.ToString());

}

I have one page in this visual studio 2005 project called default.aspx
in which I have a tracing turned on in the Page directive. I get the
trace but I do not get my custom messages as seen above. I need to
know why and how to trace from within the Global.asax file?

Thanks
Mark
 

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

Forum statistics

Threads
473,995
Messages
2,570,231
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top