Bagikan melalui


RuleSettings.Name Properti

Definisi

Mendapatkan atau mengatur nama RuleSettings objek.

public:
 property System::String ^ Name { System::String ^ get(); void set(System::String ^ value); };
[System.Configuration.ConfigurationProperty("name", DefaultValue="", IsKey=true, IsRequired=true)]
[System.Configuration.StringValidator(MinLength=1)]
public string Name { get; set; }
[<System.Configuration.ConfigurationProperty("name", DefaultValue="", IsKey=true, IsRequired=true)>]
[<System.Configuration.StringValidator(MinLength=1)>]
member this.Name : string with get, set
Public Property Name As String

Nilai Properti

Nama RuleSettings objek. Nilai default adalah string kosong ("").

Atribut

Contoh

Contoh kode berikut menunjukkan cara menggunakan Name properti . Contoh kode ini adalah bagian dari contoh yang lebih besar yang disediakan untuk HealthMonitoringSection kelas .

ruleSetting.Name = "All Errors Custom";
ruleSetting.Name = "All Errors Custom"

Keterangan

Nama unik diperlukan.

Berlaku untuk

Lihat juga