kod yardımı

Katılım
11 Ağustos 2005
Mesajlar
239
arkadaşlar hata nerede?



Private Sub GetData()
Dim MyDB As DAO.Database
Dim RS As DAO.Recordset
Dim RScount As Long

On Error GoTo ErrHandler:
Set MyDB = OpenDatabase(DBpath, False, False, "Excel 8.0")
Set RS = MyDB.OpenRecordset("select Isim, Soyad , Telefon ,from [Liste$] order by Isim")

With RS
.MoveLast
RScount = .RecordCount
.MoveFirst
End With


ListBox1.ColumnCount = RS.Fields.Count + 1
ListBox1.Column = RS.GetRows(RScount)



ErrHandler:
If RScount < 1 Then Exit Sub

RS.Close
MyDB.Close
Set RS = Nothing
Set MyDB = Nothing

End Sub
 

Zeki Gürsoy

Uzman
Uzman
Katılım
31 Aralık 2005
Mesajlar
4,369
Excel Vers. ve Dili
Office 365 (64 bit) - Türkçe
&#304;lk g&#246;ze &#231;arpan bu sat&#305;r..
Kod:
    Set RS = MyDB.OpenRecordset("select Isim, Soyad , Telefon [COLOR=Blue][B],[/B][/COLOR]from[Liste$] order by Isim")
Sat&#305;r&#305; a&#351;a&#287;&#305;daki gibi de&#287;i&#351;tirin.
Kod:
    Set RS = MyDB.OpenRecordset("select Isim, Soyad, Telefon from [Liste$] order by Isim")
 

Orion1

Uzman
Uzman
Katılım
1 Mart 2005
Mesajlar
22,254
Excel Vers. ve Dili
Win7 Home Basic TR 64 Bit

Ofis-2010-TR 32 Bit
Banada sanki Path tan&#305;mlanmam&#305;&#351; gibi geldi.:cool:
 

Zeki Gürsoy

Uzman
Uzman
Katılım
31 Aralık 2005
Mesajlar
4,369
Excel Vers. ve Dili
Office 365 (64 bit) - Türkçe
Modul d&#252;zeyinde sabit tan&#305;mlanm&#305;&#351; olabilir Evren hocam.
 
Üst