This documentation is archived and is not being maintained.

ConsumableByDesigner Property

Visual Studio .NET 2003

Returns whether the given reference is actually consumable by a designer.

[Visual Basic .NET]
Public ReadOnly Property ConsumableByDesigner() As Boolean
[Visual Basic 6]
Property Get ConsumableByDesigner() As Boolean
[C++]
HRESULT __stdcall get_ConsumableByDesigner(
   /* [out, retval] */ VARIANT_BOOL* retVal
);
[C#]
public bool ConsumableByDesigner {get;}
[JScript .NET]
public function get ConsumableByDesigner() : Boolean

Return Value

true if the given reference is consumable by a designer; false if not.

Remarks

If your reference is a project reference that is not a .NET assembly, then this property is false.

Example

' Add a reference to Microsoft.VisualStudio.VCProjectEngine and have a 
' Visual C++ .NET project loaded before running this example.
Imports EnvDTE
Imports Microsoft.VisualStudio.VCProjectEngine
Public Module Module1
Sub Test()
        Dim prj As VCProject
        Dim vcar As VCAssemblyReference
        Dim refcfg As VCReferenceConfiguration

        prj = DTE.Solution.Projects.Item(1).Object
        If prj.CanAddAssemblyReference("d:\winnt\microsoft.net _
          \framework\v1.1.4322\envdte.dll") Then
             vcar = prj.AddAssemblyReference("d:\winnt\microsoft.net _
               \framework\v1.1.4322\envdte.dll")
        End If
        refcfg = vcar.ReferenceConfigurations.Item(1)
        MsgBox("Consumable? " & refcfg.ConsumableByDesigner)
    End Sub
End Module

See Samples for Project Model Extensibility for information on how to compile and run this sample.

See Also

Applies To: VCReferenceConfiguration Object

Show: