Jump to content

[vb]listbox'ta Arama


BeyazEylem

Recommended Posts

arkadaşlar visual basic 6 da listbox1 içindeki verileri text1 den arıyacağım yani text1'e mesela an yazdım an ile ilgili tüm listeyi göstericek ama seçmiyecek mesela ben böyle yapmıstım seciyor buda veritabanında hata vermesine neden oluyor..

If Text1 <> "" Then

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

Else

List1.Text = ""

End If

Link to comment
Share on other sites

  • Administrator

text1'in change eventine

select * from tablo where id=' & text1.text & "'"

gibi bir sorgu koyarsınız. Ama a ile başlayan 5000 tane girdi vardır. o zaman bir şart koyarsın.

if len(text1.text)>2 then dersin, 3 karakter girmeden filtreleme yapmaz.

Link to comment
Share on other sites

öyle değil mesela listbox itemleri sunlar

Anne

Ankara

Aslı

Ayşe

Baba

Banka

Benzer

Bomba

Ciklet

Cennet ...

bunlar simdi text1'e yazıcam mesela a diye o listbox ta sadece

Anne

Ankara

Aslı

Ayşe

itemleri gözükücek sonra text1'e an yazdım o zmnda

Anne

Ankara

olucak

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...