Share via


Utility.IsLoginUtilityReader Method

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

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

Syntax

'Declaration
Public Shared Function IsLoginUtilityReader ( _
    storeConnection As SqlStoreConnection _
) As Boolean
'Usage
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

Parameters

Return Value

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

See Also

Reference

Utility Class

Microsoft.SqlServer.Management.Utility Namespace