IVsExpansionSession.SetEndSpan Method
Sets the position where the edit caret should be placed when the code snippet is committed to the source buffer.
Namespace: Microsoft.VisualStudio.TextManager.Interop
Assembly: Microsoft.VisualStudio.TextManager.Interop.8.0 (in Microsoft.VisualStudio.TextManager.Interop.8.0.dll)
Syntax
'Declaration
Function SetEndSpan ( _
ts As TextSpan _
) As Integer
int SetEndSpan(
TextSpan ts
)
int SetEndSpan(
[InAttribute] TextSpan ts
)
abstract SetEndSpan :
ts:TextSpan -> int
function SetEndSpan(
ts : TextSpan
) : int
Parameters
ts
Type: Microsoft.VisualStudio.TextManager.Interop.TextSpan[in] A TextSpan object that describes the position where the edit caret should go.
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 textmgr2.idl:
HRESULT IVsExpansionSession::SetEndSpan(
[in]TextSpan ts
);
Typically, a code snippet specifies a marker position in the template file where the edit caret should go when the code snippet is committed to the source buffer. This method allows that marker position to be overridden or set dynamically.
.NET Framework Security
- 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.