If you have tried to write trace info from an ASP.NET page, you know how useful this can be for debugging. If you have tried to write to trace from another tier, you might have found it too difficult. I did; until now:
To write to the current context trace (hint, hint), simply use the following call:
System.Web.HttpContext.Current.Trace.Warn(szCategory, szTraceMsg);
Yep, that's it. So simple, yet so hard to find. Now you (and I) know.
Remember Me
b, blockquote@cite, i, strike, strong, u
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.