다음을 통해 공유


IVsMonitorSelection.GetCurrentElementValue Method

Returns the value for a particular element.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

‘선언
Function GetCurrentElementValue ( _
    elementid As UInteger, _
    <OutAttribute> ByRef pvarValue As Object _
) As Integer
‘사용 방법
Dim instance As IVsMonitorSelection
Dim elementid As UInteger
Dim pvarValue As Object
Dim returnValue As Integer

returnValue = instance.GetCurrentElementValue(elementid, _
    pvarValue)
int GetCurrentElementValue(
    uint elementid,
    out Object pvarValue
)
int GetCurrentElementValue(
    [InAttribute] unsigned int elementid, 
    [OutAttribute] Object^% pvarValue
)
function GetCurrentElementValue(
    elementid : uint, 
    pvarValue : Object
) : int

Parameters

  • pvarValue
    Type: System.Object%

    [out] Pointer to data associated with the element identified by elementid.

Return Value

Type: System.Int32

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsMonitorSelection::GetCurrentElementValue(
   [in]  VSSELELEMID  elementid,
   [out] VARIANT     *pvarValue
);

Element values are entries in an array attached to the selection context of each window. Each position in the array is represented by a VSConstants.VSSELELEMID identifier. The value is specific to the element, typically a pointer to an interface. The environment sets some of the element values only; others are set by VSPackages.

Permissions

See Also

Reference

IVsMonitorSelection Interface

IVsMonitorSelection Members

Microsoft.VisualStudio.Shell.Interop Namespace