共用方式為


SPUsageDatabase Constructor (String, SPDatabaseServiceInstance, String, String)

Initializes a new instance of the [Microsoft.SharePoint.Administration.SPUsageDatabase] class based on values of the given name, serviceInstance, username, and password parameters. This constructor is for a usage database.

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

Syntax

'Declaration
Public Sub New ( _
    name As String, _
    serviceInstance As SPDatabaseServiceInstance, _
    username As String, _
    password As String _
)
'Usage
Dim name As String
Dim serviceInstance As SPDatabaseServiceInstance
Dim username As String
Dim password As String

Dim instance As New SPUsageDatabase(name, serviceInstance, _
    username, password)
public SPUsageDatabase(
    string name,
    SPDatabaseServiceInstance serviceInstance,
    string username,
    string password
)

Parameters

  • username
    Type: System.String

    Database user name for SQL authentication.

See Also

Reference

SPUsageDatabase Class

SPUsageDatabase Members

SPUsageDatabase Overload

Microsoft.SharePoint.Administration Namespace