This documentation is archived and is not being maintained.

Property Interface

Represents one property in a generic collection of properties for a given object.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

public interface Property

The Property type exposes the following members.

Public propertyApplicationInfrastructure. Microsoft Internal Use Only.
Public propertyCollectionGets the Collection containing the Property object supporting this property.
Public propertyDTEGets the top-level extensibility object.
Public propertyIndexedValueReturns one element of a list.
Public propertyNameGets the name of the object.
Public propertyNumIndicesGets the number of indices required to access the value.
Public propertyObjectSets or gets the object supporting the Property object.
Public propertyParentInfrastructure. Microsoft Internal Use Only.
Public propertyValueGets or sets the value of the property returned by the Property object.

Public methodlet_ValueSetter function to set properties values.

' Visual Studio macro.
Sub PropertyExample()
   Dim Props As Properties
   Dim PropObj As [Property]
   Dim NameValPair As String
   Props = DTE.Properties("Environment", "General")
   MsgBox("Tools – Options – Environment – General Properties Count _
   = " & Props.Count())
   For Each PropObj In Props
     NameValPair = NameValPair & (PropObj.Name & "Value = " & _
     PropObj.Value & microsoft.VisualBasic.ControlChars.CrLf)
End Sub