ServerConnection.UserProfile 屬性
取得與參考連接相關聯的使用者設定檔。
命名空間: Microsoft.SqlServer.Management.Common
組件: Microsoft.SqlServer.ConnectionInfo (在 Microsoft.SqlServer.ConnectionInfo.dll 中)
語法
'宣告
Public ReadOnly Property UserProfile As ServerUserProfiles
Get
'用途
Dim instance As ServerConnection
Dim value As ServerUserProfiles
value = instance.UserProfile
public ServerUserProfiles UserProfile { get; }
public:
property ServerUserProfiles UserProfile {
ServerUserProfiles get ();
}
member UserProfile : ServerUserProfiles
function get UserProfile () : ServerUserProfiles
屬性值
型別:Microsoft.SqlServer.Management.Common.ServerUserProfiles
ServerUserProfiles 物件值,指定與參考的連接相關聯的使用者設定檔。
範例
C#
ServerConnection conn = new ServerConnection();
Console.WriteLine(conn.UserProfile.ToString());
PowerShell
$conn = new-object Microsoft.SqlServer.Management.Common.ServerConnection
Write-Host $conn.UserProfile