共用方式為


Utility.IsLoginUtilityReader 方法

Validates whether the login used in the connection has the utility reader role.

命名空間:  Microsoft.SqlServer.Management.Utility
組件:  Microsoft.SqlServer.Management.Utility (在 Microsoft.SqlServer.Management.Utility.dll 中)

語法

'宣告
Public Shared Function IsLoginUtilityReader ( _
    storeConnection As SqlStoreConnection _
) As Boolean
'用途
Dim storeConnection As SqlStoreConnection 
Dim returnValue As Boolean 

returnValue = Utility.IsLoginUtilityReader(storeConnection)
public static bool IsLoginUtilityReader(
    SqlStoreConnection storeConnection
)
public:
static bool IsLoginUtilityReader(
    SqlStoreConnection^ storeConnection
)
static member IsLoginUtilityReader : 
        storeConnection:SqlStoreConnection -> bool
public static function IsLoginUtilityReader(
    storeConnection : SqlStoreConnection
) : boolean

參數

傳回值

型別:System.Boolean
A Boolean value indicating whether the login has the reader role. If true, the login has the role. Otherwise, false.

請參閱

參考

Utility 類別

Microsoft.SqlServer.Management.Utility 命名空間