SftTree/OCX 7.5 - ActiveX Tree Control


FindCellTextExact Method, SftTreeItems Object

Searches items for a string using an exact match.


VB.NETFoundIndex = object.FindCellTextExact(ByVal ItemIndex As Integer, ByVal ColIndex As Short, ByVal SearchString As String) As Integer
VBFoundIndex = object.FindCellTextExact(ByVal ItemIndex As Long, ByVal ColIndex As Integer, ByVal SearchString As String) As Long
C#.NETint FoundIndex = object.FindCellTextExact(int ItemIndex, short ColIndex, string SearchString);
VC++long FoundIndex = object->FindCellTextExact(long ItemIndex, short ColIndex, _bstr_t SearchString);
CHRESULT object->raw_FindCellTextExact(long ItemIndex, short ColIndex, BSTR SearchString, long* FoundIndex);


A SftTreeItems object.


The zero-based index of the item where the search begins (including ItemIndex).


The zero-based column number to be searched.


The text to be searched.


Returns the zero-based index of the item, where the specified SearchString is found. -1 is returned if no item is found matching the specified SearchString.


The FindCellTextExact method searches items for a string using an exact match.

The string described by SearchString is compared to the Cell.Text property of all items and columns involved in the search. The search starts at the item described by ItemIndex and is restricted to the column specified by ColIndex. If an item with a matching Cell.Text property is found, its zero-based index is returned, otherwise -1 is returned.

Only one column can be searched at a time. Items.FindCell can be used to search multiple columns and with additional features not available to FindCellTextExact.

The comparison of SearchString and the Cell.Text property is not case sensitive. The Cell.Text property and the SearchString must match in their entirety, partial strings do not match. To find a partial match for SearchString use the Items.FindCellText method.

SearchStringCell.Text PropertyMatchComment
ABCabcYesSame string, case is ignored
abcabc123NoNot the same string
abcThisabcNoNot the same string
abcabNoNot the same string

See Also SftTreeItems Object | Object Hierarchy

Last Updated 08/13/2020 - (email)
© 2022 Softel vdm, Inc.