共用方式為


PropertyCollection.RemoveProperty 方法

移除與指定之索引鍵相關聯的屬性。

命名空間:  Microsoft.VisualStudio.Utilities
組件:  Microsoft.VisualStudio.CoreUtility (在 Microsoft.VisualStudio.CoreUtility.dll 中)

語法

'宣告
Public Function RemoveProperty ( _
    key As Object _
) As Boolean
public bool RemoveProperty(
    Object key
)
public:
bool RemoveProperty(
    Object^ key
)
member RemoveProperty : 
        key:Object -> bool
public function RemoveProperty(
    key : Object
) : boolean

參數

  • key
    類型:Object

    要移除之屬性的索引鍵。

傳回值

類型:Boolean
如果已找到屬性並予以移除,則為 true,如果找不到屬性,則為 false。

例外狀況

例外狀況 條件
ArgumentNullException

key 為 nullnull 參考 (即 Visual Basic 中的 Nothing)。

.NET Framework 安全性

請參閱

參考

PropertyCollection 類別

Microsoft.VisualStudio.Utilities 命名空間