If anyone has worked with the ImageCombo control, you'll notice that CB_FINDSTRING does not work, even when sent to the underlying ComboBox control (via CBEM_GETCOMBOCONTROL). So the search much be conducted manually.
-This returns the zero-based index of the result; not the full string (where to make the small change to return that instead is noted)
VB Code:
Public Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hWnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
Public Const CB_GETLBTEXT = &H148
Public Const CB_GETLBTEXTLEN = &H149
Public Const CB_GETCOUNT = &H146
Public Function CBX_PartialSearch(hWnd As Long, ss As String) As Long
'ComboBoxEx (aka ImageCombo) only supports CB_FINDSTRINGEXACT
'So searching for a partial string must be done manually
Dim sBuf As String
Dim lCnt As Long
Dim lLen As Long
Dim i As Long
lCnt = SendMessage(hWnd, CB_GETCOUNT, 0, ByVal 0&)
For i = 0 To lCnt - 1
lLen = SendMessage(hWnd, CB_GETLBTEXTLEN, i, ByVal 0&)
sBuf = Space$(lLen)
Call SendMessage(hWnd, CB_GETLBTEXT, i, ByVal sBuf)
If InStr(sBuf, ss) Then
CBX_PartialSearch = i 'return sBuf if you want the full item instead of its index
Exit Function
End If
Next i
End Function