Share via


Utility.CreateUtility Method (String, SqlStoreConnection, String, SqlSecureString)

Creates a Utility object.

Namespace:  Microsoft.SqlServer.Management.Utility
Assembly:  Microsoft.SqlServer.Management.Utility (in Microsoft.SqlServer.Management.Utility.dll)

Syntax

'Declaration
Public Shared Function CreateUtility ( _
    utilityName As String, _
    sqlStoreConnection As SqlStoreConnection, _
    agentProxyAccount As String, _
    agentProxyPassword As SqlSecureString _
) As Utility
'Usage
Dim utilityName As String 
Dim sqlStoreConnection As SqlStoreConnection 
Dim agentProxyAccount As String 
Dim agentProxyPassword As SqlSecureString 
Dim returnValue As Utility 

returnValue = Utility.CreateUtility(utilityName, _
    sqlStoreConnection, agentProxyAccount, _
    agentProxyPassword)
public static Utility CreateUtility(
    string utilityName,
    SqlStoreConnection sqlStoreConnection,
    string agentProxyAccount,
    SqlSecureString agentProxyPassword
)
public:
static Utility^ CreateUtility(
    String^ utilityName, 
    SqlStoreConnection^ sqlStoreConnection, 
    String^ agentProxyAccount, 
    SqlSecureString^ agentProxyPassword
)
static member CreateUtility : 
        utilityName:string * 
        sqlStoreConnection:SqlStoreConnection * 
        agentProxyAccount:string * 
        agentProxyPassword:SqlSecureString -> Utility
public static function CreateUtility(
    utilityName : String, 
    sqlStoreConnection : SqlStoreConnection, 
    agentProxyAccount : String, 
    agentProxyPassword : SqlSecureString
) : Utility

Parameters

  • utilityName
    Type: System.String
    A string value that specifies the name of the utility.
  • agentProxyAccount
    Type: System.String
    A string value that specifies the agent proxy account.
  • agentProxyPassword
    Type: SqlSecureString
    A SqlSecureString object that contains the password.

Return Value

Type: Microsoft.SqlServer.Management.Utility.Utility
A Utility object.

See Also

Reference

Utility Class

CreateUtility Overload

Microsoft.SqlServer.Management.Utility Namespace