VCFileCodeModel Interface
An object representing the code elements in a source file.
Namespace: Microsoft.VisualStudio.VCCodeModel
Assembly: Microsoft.VisualStudio.VCCodeModel (in Microsoft.VisualStudio.VCCodeModel.dll)
Syntax
'Declaration
<GuidAttribute("DF69B061-2447-11D7-8BF6-00B0D03DAA06")> _
Public Interface VCFileCodeModel _
Inherits FileCodeModel2
'Usage
Dim instance As VCFileCodeModel
[GuidAttribute("DF69B061-2447-11D7-8BF6-00B0D03DAA06")]
public interface VCFileCodeModel : FileCodeModel2
[GuidAttribute(L"DF69B061-2447-11D7-8BF6-00B0D03DAA06")]
public interface class VCFileCodeModel : FileCodeModel2
public interface VCFileCodeModel extends FileCodeModel2
Remarks
The VCFileCodeModel object is used to modify an existing source file and the code elements contained within.
Note
A large part of the functionality of this object is provided by the Visual Studio FileCodeModel object. For more information, see FileCodeModel object.
See How to: Compile Example Code for Visual C++ Code Model Extensibility for information on how to compile and run this sample.
Examples
This example retrieves the VCFileCodeModel for the first project item of the current solution. It assumes a default MFC project is open.
Sub GetSourceFile()
Dim vcFile as VCFileCodeModel
Dim project as Project
project = DTE.Solution.Item(1)
vcFile = project.ProjectItems.Item(1).FileCodeModel
End Sub