Find Code:
All Words
Any of the Words
Exact Phrase
Home
:
Code
:
Forums
:
Submit
:
Mailing List
:
About
:
Contact
Code
All
VB.NET
ASP.NET
C#
VB Classic
ASP Classic
Snippets
Popular
Resources
Submit Code
Forums
Articles
Tips
Links
Books
Contest
Link to us
This code works similar to the index tab in any He...
Author:
R.Dinesh
E-mail:
Click to e-mail author
Submitted:
8/9/2001
Version:
VB5
Compatibility:
VB5, VB6
Category:
String Manipulation
Views:
10500
This code works similar to the index tab in any Help Window. The object is when we type some text in the combo(text) box a similar entry is searched for in the list box entries.If found it is highlighted.
Declarations:
'none
Code:
'Just add a ComboBox and ListBox to the form and paste 'this code in relevant areas 'After adding just add some dummy entries in the list 'box.Then start typing in the text(combo) box Private Sub Combo1_Change() For i = 0 To List1.ListCount - 1 If Not Trim(Combo1.Text) = "" Then If Trim(Combo1.Text) = Mid(List1.List(i), 1,_ Len(Trim(Combo1.Text))) Then List1.Selected(i) = True Exit For End If Else List1.Selected(0) = True End If Next i End Sub
Home
|
Forums
|
Submit
|
Books
|
Mailing List
|
Advertising
|
About
|
Contact
© 2024 A1VBCode. All rights reserved.
Legal disclaimer & terms of use
Privacy statement