Export (0) Print
Expand All

IVsTextLines.GetLengthOfLine Method

Returns the length of a line in the buffer.

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

int GetLengthOfLine(
	int iLine,
	out int piLength
)

Parameters

iLine
Type: System.Int32

[in] Number of the line whose length is requested.

piLength
Type: System.Int32

[out] Pointer to the length of the line.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

COM Signature

From textmgr.idl:

HRESULT IVsTextLines::GetLengthOfLine(
   [in] long iLine,
   [out] long *piLength
);

This method is used heavily by views and is reasonably efficient in all implementations.

Show:
© 2014 Microsoft