Which of the following attributes of the trace element is used to state whether tracing is enabled for
an application?
A.
localOnly
B.
pageOutput
C.
enabled
D.
writeToDiagnosticsTrace
Explanation:
The enabled attribute of the trace element is an optional Boolean attribute. It is used to state
whether tracing is enabled for an application. In order to use the Trace.axd viewer, it is necessary to
enable tracing. By default, the Trace.axd viewer is added to the httpHandlers element. Its default
value is set to false.
Answer A is incorrect. The localOnly attribute of the trace element is an optional boolean attribute.
It is used to identify whether the trace viewer is accessible only on the host Web server. If false, the
trace viewer is accessible from any computer. By default, the trace viewer is added to the
httpHandlers element. By default, the localOnly attribute is set to true.
Answer D is incorrect. The writeToDiagnosticsTrace attribute of the trace element is an optional
boolean attribute. It is used to identify whether ASP.NET Trace messages are forwarded to the
System.Diagnostics tracing infrastructure. This applies to any listeners that are registered to display
Trace messages. This attribute is new in .NET Framework version 2.0. By default, it is set to false.
Answer B is incorrect. The pageOutput attribute of the trace element is an optional boolean
attribute. It is used to identify whether trace output is rendered at the end of each page. If false,
trace output is accessible all the way through the trace utility only. By default, the pageOutput
attribute is set to false.