VCFileCodeModel.CodeElementFromPoint(TextPoint, vsCMElement) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets a code element at a specific ___location in a source file.
public:
EnvDTE::CodeElement ^ CodeElementFromPoint(EnvDTE::TextPoint ^ Point, EnvDTE::vsCMElement Scope);
public:
EnvDTE::CodeElement ^ CodeElementFromPoint(EnvDTE::TextPoint ^ Point, EnvDTE::vsCMElement Scope);
EnvDTE::CodeElement CodeElementFromPoint(EnvDTE::TextPoint const & Point, EnvDTE::vsCMElement Scope);
[System.Runtime.InteropServices.DispId(5)]
public EnvDTE.CodeElement CodeElementFromPoint(EnvDTE.TextPoint Point, EnvDTE.vsCMElement Scope);
[System.Runtime.InteropServices.DispId(5)]
public EnvDTE.CodeElement CodeElementFromPoint(EnvDTE.TextPoint POINT, EnvDTE.vsCMElement scope);
[<System.Runtime.InteropServices.DispId(5)>]
abstract member CodeElementFromPoint : EnvDTE.TextPoint * EnvDTE.vsCMElement -> EnvDTE.CodeElement
Public Function CodeElementFromPoint (Point As TextPoint, Scope As vsCMElement) As CodeElement
Public Function CodeElementFromPoint (POINT As TextPoint, scope As vsCMElement) As CodeElement
Parameters
- PointPOINT
- TextPoint
Required. A TextPoint object representing the editor ___location for which you want a code element.
- Scopescope
- vsCMElement
Required. A vsCMElement value representing the code element of the specified type that contains the editor ___location.
Returns
A CodeElement object.
Implements
- Attributes
Remarks
CodeElementFromPoint returns the code element associated with the TextPoint based on the specified scope or granularity of containment. If no code element of the specified type contains the editor ___location, then CodeElementFromPoint fails.