StrongNameIdentityPermission.Name 屬性

定義

取得或設定強式名稱身分識別的簡單名稱部分。Gets or sets the simple name portion of the strong name identity.

public:
 property System::String ^ Name { System::String ^ get(); void set(System::String ^ value); };
public string Name { get; set; }
member this.Name : string with get, set
Public Property Name As String

屬性值

String

身分識別的簡單名稱。The simple name of the identity.

例外狀況

該值為空字串 ("")。The value is an empty string ("").

無法擷取屬性值,因為它包含模稜兩可的身分識別。The property value cannot be retrieved because it contains an ambiguous identity.

備註

屬性的值 Name 可以是完整的名稱,也可以由最後一個位置中的萬用字元來修改; 例如,MyCompany. MyDepartment. myfile.txt 和 MyCompany. MyDepartment 都是有效的名稱。The value of the Name property can be an exact name or can be modified by a wildcard character in the final position; for example, both MyCompany.MyDepartment.MyFile and MyCompany.MyDepartment.* are valid names. 如果您嘗試將屬性設 Name 為空字串 ( "" ) , ArgumentException 則會擲回。If you attempt to set the Name property to an empty string (""), an ArgumentException is thrown.

適用於