Share via


SPDiagnosticsArea Constructor (String, String, UInt32, UInt32, Boolean, IEnumerable<SPDiagnosticsCategory>)

Initializes a new instance of the SPDiagnosticsArea class by using the specified parameters.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

Syntax

'Declaration
Public Sub New ( _
    name As String, _
    localizedName As String, _
    messageId As UInteger, _
    areaId As UInteger, _
    hidden As Boolean, _
    categories As IEnumerable(Of SPDiagnosticsCategory) _
)
'Usage
Dim name As String
Dim localizedName As String
Dim messageId As UInteger
Dim areaId As UInteger
Dim hidden As Boolean
Dim categories As IEnumerable(Of SPDiagnosticsCategory)

Dim instance As New SPDiagnosticsArea(name, localizedName, _
    messageId, areaId, hidden, categories)
public SPDiagnosticsArea(
    string name,
    string localizedName,
    uint messageId,
    uint areaId,
    bool hidden,
    IEnumerable<SPDiagnosticsCategory> categories
)

Parameters

  • name
    Type: System.String

    The name of the custom diagnostic area.

  • localizedName
    Type: System.String

    The localized name of the custom diagnostic area or a null reference (Nothing in Visual Basic). If the value is a null reference (Nothing in Visual Basic), then the SPDiagnosticsServiceBase will attempt to find the localized name from the resource DLL specified in the SPDiagnosticsServiceBase using the messageId as the message index in the resource DLL.

  • messageId
    Type: System.UInt32

    This message ID is used if the localizedName is a null reference (Nothing in Visual Basic) and if the SPDiagnosticsServiceBase contains a resource DLL.

  • areaId
    Type: System.UInt32

    The unique numeric ID representing the area. The SPDiagnosticsService uses the value internally to persist configuration. If you use zero, then the DiagnosticeServiceBase will assign a unique ID.

  • hidden
    Type: System.Boolean

    true if the SPDiagnosticsArea object is hidden from the Configure Diagnostic Logging page of the Central Administration site; otherwise, false.

Remarks

The collection of categories for this area.

See Also

Reference

SPDiagnosticsArea Class

SPDiagnosticsArea Members

SPDiagnosticsArea Overload

Microsoft.SharePoint.Administration Namespace