How can I use Tracing in Custom Components?
In Custom Components, you can use tracing if you reference the System.Web namespace and use the HttpContext.Current object to get a reference to the current context.
Also make sure to set the following directives:
For Page Level Tracing set Page Directive as
For Application Level Tracing modify corresponding web.config as