Export (0) Print
Expand All

VCFile.FileConfigurations Property 

The list of configurations on the selected file.

Namespace: Microsoft.VisualStudio.VCProjectEngine
Assembly: Microsoft.VisualStudio.VCProjectEngine (in microsoft.visualstudio.vcprojectengine.dll)

Object FileConfigurations { get; }
/** @property */
Object get_FileConfigurations ()

function get FileConfigurations () : Object

Property Value

An array of configurations.

The configurations on the file correspond to the configurations on the project. See Samples for Project Model Extensibility for information about how to compile and run this example.

The following example uses the FileConfigurations property in the integrated development environment (IDE):

' add reference to Microsoft.VisualStudio.VCProjectEngine
Imports EnvDTE
Imports Microsoft.VisualStudio.VCProjectEngine

Public Module Module1
    Sub Test()
        Dim idx, idx2 As Integer
        Dim mycollection As IVCCollection
        Dim file As VCFile
        Dim prj As VCProject
        prj = DTE.Solution.Projects.Item(1).Object
        mycollection = prj.Files
        MsgBox(mycollection.Count)
        For idx = 1 To mycollection.Count
            file = mycollection.Item(idx)
            For idx2 = 1 To file.FileConfigurations.Count
                MsgBox(file.FileConfigurations.Item(idx2).Name())
            Next
        Next
    End Sub
End Module
Show:
© 2014 Microsoft