Bagikan melalui


PropertyCollection.GetProperty Method (Object)

Gets the property associated with the specified key.

Namespace:  Microsoft.VisualStudio.Utilities
Assembly:  Microsoft.VisualStudio.CoreUtility (in Microsoft.VisualStudio.CoreUtility.dll)

Syntax

'Declaration
Public Function GetProperty ( _
    key As Object _
) As Object
public Object GetProperty(
    Object key
)
public:
Object^ GetProperty(
    Object^ key
)
member GetProperty : 
        key:Object -> Object
public function GetProperty(
    key : Object
) : Object

Parameters

  • key
    Type: Object

    The key.

Return Value

Type: Object
The property value, or nulla null reference (Nothing in Visual Basic) if the property is not set.

Exceptions

Exception Condition
ArgumentNullException

key is nulla null reference (Nothing in Visual Basic).

KeyNotFoundException

key does not exist in the property collection.

.NET Framework Security

See Also

Reference

PropertyCollection Class

GetProperty Overload

Microsoft.VisualStudio.Utilities Namespace