次の方法で共有


VCFile.FileConfigurations プロパティ

選択されたファイルの構成のリストです。

名前空間 :  Microsoft.VisualStudio.VCProjectEngine
アセンブリ :  Microsoft.VisualStudio.VCProjectEngine (Microsoft.VisualStudio.VCProjectEngine.dll 内)

構文

'宣言
ReadOnly Property FileConfigurations As Object
'使用
Dim instance As VCFile
Dim value As Object

value = instance.FileConfigurations
Object FileConfigurations { get; }
property Object^ FileConfigurations {
    Object^ get ();
}
function get FileConfigurations () : Object

プロパティ値

型 : System.Object

構成の配列です。

解説

ファイルの構成はプロジェクトの構成に対応しています。このサンプル コードをコンパイルして実行する方法については、「方法 : プロジェクト モデル機能拡張のプログラム例をコンパイルする」を参照してください。

統合開発環境 (IDE) で FileConfigurations プロパティを使用するサンプル コードを次に示します。

' 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

アクセス許可

  • 直前の呼び出し元に対する完全な信頼。このメンバは、部分的に信頼されているコードから使用することはできません。詳細については、「部分信頼コードからのライブラリの使用」を参照してください。

参照

参照

VCFile インターフェイス

VCFile メンバ

Microsoft.VisualStudio.VCProjectEngine 名前空間