HttpTracingSection Class [IIS 7 and higher]

IIS 7.0

Represents an HTTP tracing configuration section.

class HttpTracingSection : ConfigurationSectionWithCollection

The following table lists the methods exposed by the HttpTracingSection class.

Name

Description

Add

(Inherited from ConfigurationSectionWithCollection.)

Clear

(Inherited from ConfigurationSectionWithCollection.)

Get

(Inherited from ConfigurationSectionWithCollection.)

GetAllowDefinition

(Inherited from ConfigurationSection.)

GetAllowLocation

(Inherited from ConfigurationSection.)

Remove

(Inherited from ConfigurationSectionWithCollection.)

RevertToParent

(Inherited from ConfigurationSection.)

SetAllowDefinition

(Inherited from ConfigurationSection.)

SetAllowLocation

(Inherited from ConfigurationSection.)

The following table lists the properties exposed by the HttpTracingSection class.

Name

Description

TraceUrls

A TraceUrlSettings value that specifies tracing for specific types of requests.

Location

(Inherited from ConfigurationSection.) A key property.

Path

(Inherited from ConfigurationSection.) A key property.

SectionInformation

(Inherited from ConfigurationSection.)

This class contains no subclasses.

This class corresponds to the <httpTracing> section in ApplicationHost.config and is used for Event Tracing for Windows (ETW) request-based tracing.

The following code example displays the contents of the TraceUrls property.

' Connect to the WMI WebAdministration namespace.
Set oWebAdmin = GetObject( _
    "winmgmts:root\WebAdministration")

' Get the HTTP tracing section.
Set oSection = oWebAdmin.Get( _
    "HttpTracingSection.Path=" & _
    "'MACHINE/WEBROOT/APPHOST',Location=''")

' Display the class name of the section.
WScript.Echo "[ " & oSection.Path_.Class & " ]"

' Display the path.
WScript.Echo "Path: " & oSection.Path

' Display the trace url values.
For Each strElement In oSection.TraceUrls.TraceUrls
    WScript.Echo strElement.Value
Next

Type

Description

Client

Requires IIS 7 on Windows Vista.

Server

Requires IIS 7 on Windows Server 2008.

Product

IIS 7

MOF file

WebAdministration.mof

Community Additions

ADD
Show: