Share via


Connection.IsUserServerAdministrator Property

Definition

Gets a value indicating whether the user opening the connection is a member of the Administrators user group.

public:
 property bool IsUserServerAdministrator { bool get(); };
public bool IsUserServerAdministrator { get; }
member this.IsUserServerAdministrator : bool
Public ReadOnly Property IsUserServerAdministrator As Boolean

Property Value

true if the user opening the connection is a member of the Administrators user group; otherwise, false.

Examples

public string IsUserServerAdministratorStr(IServiceProvider sp) {
    Connection con = (Connection)sp.GetService(typeof(Connection));
    return con.IsUserServerAdministrator.ToString();
}

Applies to