Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

VCCodeFunction Object

Visual Studio .NET 2003

An object defining a function construct in a source file.

[Visual Basic .NET]
Public Interface VCCodeFunction
   Inherits IDispatch
[Visual Basic 6]
Class VCCodeFunction
[C++]
interface VCCodeFunction : IDispatch
[C#]
public interface VCCodeFunction : IDispatch
[JScript .NET]
public interface VCCodeFunction extends IDispatch

Remarks

The VCCodeFunction object provides code model functionality to existing Visual C++ IDE solutions at the function level. Primarily, this object is used to access or modify an existing function construct.

Note   A large part of the functionality of this object is provided by the Visual Studio CodeFunction object. For more information, see CodeFunction object.

Requirements

Namespace: Microsoft.VisualStudio.VCCodeModel

File: vcpkg.dll

Example

This example retrieves all functions in the solution and displays the name of each.

Sub GetFunctions()
    Dim vcCM as VCCodeModel
    Dim vcFunc as VCCodeFunction
    vcCM = DTE.Solution.Item(1).CodeModel
    For Each vcFunc in vcCM.Functions
        MsgBox(vcFunc.DisplayName)
End Sub

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

See Also

AddFunction Method [Variation 1] (General Extensibility) | VCCodeFunction Object Properties, Methods, and Events | Visual C++ Extensibility Object Model

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.