IVsTextFind.Find Method

Definition

Finds a given block of text in the text buffer.

public:
 int Find(System::String ^ pszText, int iStartLine, int iStartIndex, int iEndLine, int iEndIndex, int iFlags, [Runtime::InteropServices::Out] int % piLine, [Runtime::InteropServices::Out] int % piCol);
int Find(std::wstring const & pszText, int iStartLine, int iStartIndex, int iEndLine, int iEndIndex, int iFlags, [Runtime::InteropServices::Out] int & piLine, [Runtime::InteropServices::Out] int & piCol);
public int Find (string pszText, int iStartLine, int iStartIndex, int iEndLine, int iEndIndex, int iFlags, out int piLine, out int piCol);
abstract member Find : string * int * int * int * int * int * int * int -> int
Public Function Find (pszText As String, iStartLine As Integer, iStartIndex As Integer, iEndLine As Integer, iEndIndex As Integer, iFlags As Integer, ByRef piLine As Integer, ByRef piCol As Integer) As Integer

Parameters

pszText
String

[in] Pointer to a null terminated string containing the text.

iStartLine
Int32

[in] Integer containing the start line.

iStartIndex
Int32

[in] Integer index value for the starting character within the line. Must be less than or equal to the length of line.)

iEndLine
Int32

[in] Integer value for the end of the line.

iEndIndex
Int32

[in] Integer index value for the ending character in the line. Must be less than or equal to the length of the line.)

iFlags
Int32

[in] Flags from the TextFindMode enumeration.

piLine
Int32

[out] Pointer to the line number where the desired text is located.

piCol
Int32

[out] Pointer to the column number on the line where the desired text is located.

Returns

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

Remarks

COM Signature

From textmgr.idl:

HRESULT IVsTextFind::Find(  
   [in] const WCHAR *pszText,   
   [in] long iStartLine,   
   [in] CharIndex iStartIndex,   
   [in] long iEndLine,   
   [in] CharIndex iEndIndex,   
   [in] long iFlags,   
   [out] long *piLine,   
   [out] long *piCol  
);  

Applies to