Name 属性
Gets or sets the name of the managed instance.
命名空间: Microsoft.SqlServer.Management.Utility
程序集: Microsoft.SqlServer.Management.Utility(在 Microsoft.SqlServer.Management.Utility.dll 中)
语法
声明
<SfcKeyAttribute()> _
<SfcPropertyAttribute(SfcPropertyFlags.None Or SfcPropertyFlags.Required Or SfcPropertyFlags.ReadOnlyAfterCreation)> _
Public Property Name As String
Get
Protected Set
用法
Dim instance As ManagedInstance
Dim value As String
value = instance.Name
instance.Name = value
[SfcKeyAttribute()]
[SfcPropertyAttribute(SfcPropertyFlags.None|SfcPropertyFlags.Required|SfcPropertyFlags.ReadOnlyAfterCreation)]
public string Name { get; protected set; }
[SfcKeyAttribute()]
[SfcPropertyAttribute(SfcPropertyFlags::None|SfcPropertyFlags::Required|SfcPropertyFlags::ReadOnlyAfterCreation)]
public:
property String^ Name {
String^ get ();
protected: void set (String^ value);
}
[<SfcKeyAttribute()>]
[<SfcPropertyAttribute(SfcPropertyFlags.None|SfcPropertyFlags.Required|SfcPropertyFlags.ReadOnlyAfterCreation)>]
member Name : string with get, set
function get Name () : String
protected function set Name (value : String)
属性值
类型:System. . :: . .String
A String value that specifies the name of the managed instance.
示例
VC#
ManagedInstance managedInstance;
managedInstance = new ManagedInstance ();
System.Console.WriteLine(managedInstance.Name);
VB
Dim managedInstance As ManagedInstance
managedInstance = New ManagedInstance()
System.Console.WriteLine(managedInstance.Name)
PowerShell
$managedInstance = New-Object Microsoft.SqlServer.Management.Utility.ManagedInstance
Write-Host $managedInstance.Name