VCFilter::SourceControlFiles Property
Gets or sets a value indicating whether files added to the filter are automatically placed under source code control.
Assembly: Microsoft.VisualStudio.VCProjectEngine (in Microsoft.VisualStudio.VCProjectEngine.dll)
Property Value
Type: System::Booleantrue if files are placed under source code control; otherwise, false.
By default, all files added to a project under source code control are expected to be automatically added to source code control as well. An exception would be when you want to add generated files, such as the .c files generated by MIDL, to the project to get them built during a build. Such generated files do not belong under source code control.
See How to: Compile Example Code for Project Model Extensibility for information about how to compile and run this example.
The following example uses SourceControlFiles in the integrated development environment (IDE):
' Macro code. ' add reference to Microsoft.VisualStudio.VCProjectEngine Imports EnvDTE Imports Microsoft.VisualStudio.VCProjectEngine Public Module Module1 Sub Test() Dim mycollection As IVCCollection Dim filter As VCFilter Dim prj As VCProject prj = DTE.Solution.Projects.Item(1).Object mycollection = prj.Filters ' mycollection.Count has count of files filter = mycollection.Item(1) MsgBox(filter.SourceControlFiles) End Sub End Module