Поделиться через


VirtualPoint.CodeElement Property

Returns the code element at the VirtualPoint location.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Syntax

'Declaration
ReadOnly Property CodeElement ( _
    Scope As vsCMElement _
) As CodeElement
CodeElement this[
    vsCMElement Scope
] { get; }
property CodeElement^ CodeElement[[InAttribute] vsCMElement Scope] {
    CodeElement^ get ([InAttribute] vsCMElement Scope);
}
abstract CodeElement : CodeElement
JScript does not support indexed properties.

Parameters

  • Scope
    Type: EnvDTE.vsCMElement
    Required. A vsCMElement constant indicating the code element with the specified kind that contains the editor location.

Property Value

Type: EnvDTE.CodeElement
A CodeElement object.

Implements

TextPoint.CodeElement[vsCMElement]

Remarks

If the specified code element type is not at the VirtualPoint location, then the CodeElement object returns Nothing. The CodeElement object is a shortcut for TextPoint.Parent.Parent.ProjectItem.CodeModel.CodeElementFromPoint(TextPoint, <scope>)

.NET Framework Security

See Also

Reference

VirtualPoint Interface

EnvDTE Namespace

Other Resources

How to: Compile and Run the Automation Object Model Code Examples