Çektiğim verileri sütun başlıkları ile getirmem mümkün mü?
Yada ilk satıra manuel veri girip, gelen verileri ardından yüklemek?
Kod: Tümünü seç
Call MDC
sql = "SELECT * FROM Tablo1 WHERE SUT02 LIKE '%" & sut02 & "%' AND " & _
"SUT03 LIKE '%" & sut03 & "%' AND " & _
"SUT05 LIKE '%" & sut05 & "%' AND " & _
"SUT06 LIKE '%" & sut06 & "%' AND " & _
"SUT07 LIKE '%" & sut07 & "%' AND " & _
"SUT08 LIKE '%" & sut08 & "%' AND " & _
"(SUT09 LIKE '%" & sut09 & "%' OR SUT10 LIKE '%" & sut09 & "%') AND " & _
"SUT11 LIKE '%" & sut11 & "%' AND " & _
"SUT12 LIKE '%" & sut12 & "%' AND " & _
"SUT13 LIKE '%" & sut13 & "%' ORDER BY SUT01"
Set rs = Cn.Execute(sql)
ListBox1.RowSource = Empty
ListBox1.Column = rs.GetRows
Cn.Close
Set Cn = Nothing: Set rs = Nothing: