Newbies need help.........Urgent please help.....!!

Newbies need help.........Urgent please help.....!!

Post by Jefferson Chan » Thu, 06 Aug 1998 04:00:00



Can I search the List1.ItemData(List1.ListIndex) like the way I to search
for List1.text in below?

Private Sub Text1_Change()
    Dim i
    Dim strSearch As String
    strSearch = Text1.Text
    If strSearch = "" Then Exit Sub
    i = SendMessage(List1.hWnd, LB_FINDSTRING, -1, ByVal strSearch)
    If i < 0 Then
        MsgBox "Not Found"
        Exit Sub
    End if
    List1.TopIndex = i
    List1.ListIndex = i
End Sub

Please help.....

 
 
 

Newbies need help.........Urgent please help.....!!

Post by Vlad Azarkhi » Fri, 07 Aug 1998 04:00:00


This one is simplier and it does work :

Private Sub Text1_Change()

  list1.ListIndex = SendMessage(List1.hwnd, LB_FINDSTRING, -1, ByVal
CStr(Text1))

End Sub

You don't need to yell (display MsgBox), each time string not found.

Best Regards,
Vlad A.


> Can I search the List1.ItemData(List1.ListIndex) like the way I to search
> for List1.text in below?

> Private Sub Text1_Change()
>     Dim i
>     Dim strSearch As String
>     strSearch = Text1.Text
>     If strSearch = "" Then Exit Sub
>     i = SendMessage(List1.hWnd, LB_FINDSTRING, -1, ByVal strSearch)
>     If i < 0 Then
>         MsgBox "Not Found"
>         Exit Sub
>     End if
>     List1.TopIndex = i
>     List1.ListIndex = i
> End Sub

> Please help.....


 
 
 

Newbies need help.........Urgent please help.....!!

Post by Jefferson Chan » Sat, 08 Aug 1998 04:00:00


Vlad Azarkhin, thank you very much ^_^;  thanks........ thank you..........


>This one is simplier and it does work :

>Private Sub Text1_Change()

>  list1.ListIndex = SendMessage(List1.hwnd, LB_FINDSTRING, -1, ByVal
>CStr(Text1))

[........]
 
 
 

1. Newbies need help......Urgent please help!!

Can I search the List1.ItemData(List1.ListIndex) like the way I to search
for List1.text in below?

Private Sub Text1_Change()
    Dim i
    Dim strSearch As String
    strSearch = Text1.Text
    If strSearch = "" Then Exit Sub
    i = SendMessage(List1.hWnd, LB_FINDSTRING, -1, ByVal strSearch)
    If i < 0 Then
        MsgBox "Not Found"
        Exit Sub
    End if
    List1.TopIndex = i
    List1.ListIndex = i
End Sub

Please help.....

2. calculation split in two fields

3. Please Help Urgent help needed!!!!

4. How to copy data from one database to another in small amounts

5. HELP PLEASE: URGENT: Need help forming a multi table query

6. OLE Picture

7. Urgent help needed please help

8. COMBO BOX, PLEASE HELP, PLEASE HELP, PLEASE HELP!

9. Please help.....just simple Newbies Question

10. Please Help Me I very newbies

11. Please Please help !!! Crystal Report Help Needed

12. I need help in designing a school database Please Please help