VsTextViewClass.GetNearestPosition(Int32, Int32, Int32, Int32) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Converts a line and column index to a text stream position.
public:
virtual int GetNearestPosition(int iLine, int iCol, [Runtime::InteropServices::Out] int % piPos, [Runtime::InteropServices::Out] int % piVirtualSpaces) = Microsoft::VisualStudio::TextManager::Interop::IVsTextView::GetNearestPosition;
public:
virtual int GetNearestPosition(int iLine, int iCol, [Runtime::InteropServices::Out] int % piPos, [Runtime::InteropServices::Out] int % piVirtualSpaces);
virtual int GetNearestPosition(int iLine, int iCol, [Runtime::InteropServices::Out] int & piPos, [Runtime::InteropServices::Out] int & piVirtualSpaces);
public virtual int GetNearestPosition (int iLine, int iCol, out int piPos, out int piVirtualSpaces);
abstract member GetNearestPosition : int * int * int * int -> int
override this.GetNearestPosition : int * int * int * int -> int
Public Overridable Function GetNearestPosition (iLine As Integer, iCol As Integer, ByRef piPos As Integer, ByRef piVirtualSpaces As Integer) As Integer
Parameters
- iLine
- Int32
[in] Integer containing the line index.
- iCol
- Int32
[in] Integer containing the column index. Viewcol coordinates might include virtual space.
- piPos
- Int32
[out] Pointer to an integer containing the position in the text stream.
- piVirtualSpaces
- Int32
[out] Pointer to an integer containing the number of virtual spaces.
Returns
If the method succeeds, it returns S_OK. If it fails, it returns an error code.