ASP.NET Tracing

ASP.NET provides an extremely handy tool for discovering bottlenecks in your application. Specify trace="true" in the Page directive of your Web form as in the following line:

<% @Page debug="true" trace="true" Language="VB" %>

The next time you load your Web form, you will notice that ASP.NET has automatically printed out a wealth of information for you below your form. In addition to the entire control tree for your form, all server variables and request values, you can see exactly how long each stage of the page's life cycle took. You can see this in Figure 23.1.

Figure 23.1. Trace information provided automatically by ASP.NET.

The last two columns in the Trace Information section provide the exact (probably more exact than ...

Get Sams Teach Yourself ADO.NET in 24 Hours now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.