Gets a particular element.
Namespace: Microsoft.VisualStudio.Modeling
Assembly: Microsoft.VisualStudio.Modeling.Sdk (in Microsoft.VisualStudio.Modeling.Sdk.dll)
Syntax
'宣言
Function GetElement ( _
elementId As Guid _
) As ModelElement
'使用
Dim instance As IElementDirectory
Dim elementId As Guid
Dim returnValue As ModelElement
returnValue = instance.GetElement(elementId)
ModelElement GetElement(
Guid elementId
)
ModelElement^ GetElement(
Guid elementId
)
function GetElement(
elementId : Guid
) : ModelElement
Parameters
elementId
Type: System.GuidThe ID of the element to be retrieved.
Return Value
Type: Microsoft.VisualStudio.Modeling.ModelElement
A ModelElement object.
Remarks
If the element is not found, an exception is thrown.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.