Can Ajax and ASP.NET tracing be used on the same page?

I'm using the Ajax refresh panel and recently added ASP.NET tracing code to aid in debugging. All of a sudden, I started getting PageRequestManagerParseErrorExceptions when any Ajax code is executed.

For example:
  Trace.Write ("Done setting employeeId.");

This appears to be due to the fact that I am not allowed to use "server trace" along with Ajax. (according to this post from Eilon Lipton ).

It's true? Am I not allowed to use the awesome ASP.NET tracing engine? It would be a shame.

+1


source to share


1 answer


Setting pageOutput = "false" on the trace element in web.config seems to fix the problem.



Use ASP.NET tracing, but rather write to a regular diagnostic trace by setting the writeToDiagnosticsTrace attribute to "true" (this is in the trace element in the web.config file).

+3


source







All Articles