Dim c
ListBox1.Clear
For Each c In Sheet10.Range("A1:A100")
If c = TextBox66.Text Then
ListBox1.AddItem c
ListBox1.AddItem c.Offset(0, 1)
ListBox1.AddItem c.Offset(0, 2)
ListBox1.AddItem c.Offset(0, 3)
ListBox1.List(ListBox1.ListCount - 1, 1) = c.Offset(0, 1).Value
ListBox1.List(ListBox1.ListCount - 1, 2) = c.Offset(0, 2).Value
ListBox1.List(ListBox1.ListCount - 1, 3) = c.Offset(0, 3).Value
End If
اطلاعات جستجو
Collapse
X
-
اطلاعات جستجو
سلام کدی برای جستجو دارم اما در یک ستون در لیست باکس می اید من میخواهم در یک ردیف بیاید.
ضمنا اگر بر اساس دو خانه بخواهیم جستجو کنیم(دو تکس باکس) مثلا بر اساس سال تولد وشماره شناسنامه انوقت چطوری کد بنویسیم .ممنونکد PHP:Last edited by ~M*E*H*D*I~; 2014/02/23, 21:56. -
این قسمت رو برای چی اضافه کردید؟
کد PHP:
ListBox1.List(ListBox1.ListCount - 1, 1) = c.Offset(0, 1).Value
ListBox1.List(ListBox1.ListCount - 1, 2) = c.Offset(0, 2).Value
ListBox1.List(ListBox1.ListCount - 1, 3) = c.Offset(0, 3).Value
[CENTER]
[SIGPIC][/SIGPIC]
[/CENTER] -
-
کامنت
-
-
قسمت دوم رو حذف کنید باید درست بشه
کد PHP:ListBox1.List(ListBox1.ListCount - 1, 1) = c.Offset(0, 1).Value
ListBox1.List(ListBox1.ListCount - 1, 2) = c.Offset(0, 2).Value
ListBox1.List(ListBox1.ListCount - 1, 3) = c.Offset(0, 3).Value
[CENTER]
[SIGPIC][/SIGPIC]
[/CENTER]کامنت
-
-
کامنت


کامنت