Finds the next entry in the index that exactly or partially matches the passed key.
bValue = object.brFindNext( sKey, [ vsIId])
Parameter | Description |
---|---|
bValue | The return value is a Boolean data type that is True if the next entry in the index is an exact or partial match to sKey. |
object | An object variable that represents a clsD3Index object. |
sKey | A String containing the search string. |
vsIId | Optional. A Variant (String subtype) containing the item-id of the D3 item whose index matches sKey. This parameter returns the same result as the brIndexId property. |
If no more matches to sKey are found in the index, then the return value is False. The item-id returned is that of the next sequential entry in the index, unless this is past the end of the index.
If sKey is null, then the first entry in the index is returned.
Sub Search_Click() Dim oFile As clsD3File Dim oIndex As clsD3Index Dim sSearch As String OpenConnection ' Subroutine to establish connection Set oFile = oConn.brOpenFile("customers") Set oIndex = oFile.brRoot("a1") ' Retrieve a search criteria from text box sSearch = Text2.Text Combo1.Clear ' A combo box will contain all customers with ' a name beginning with search criteria Do While oIndex.brFindNext(sSearch) Combo1.AddItem oIndex.brIndexKey Loop oConn.brCloseFile oFile CloseConnection ' Subroutine to close connection End Sub
D3IndexCompkey: key - with the 'c' operator
orD3IndexNextKey: key - with the 'n' operator