Set ExcelDosyasi = CreateObject("Excel.Application")
Dim i As Integer
On Error Resume Next
With ExcelDosyasi
.Application.Visible = True
.UserControl = True
.Workbooks.Open FileName:=CurrentProject.Path & "\aktarma.xls"
Dim rs As Recordset
Set rs = CurrentDb.OpenRecordset(Me.RecordSource)
i = 0
rs.MoveFirst
Do Until rs.EOF
i = i + 1
.CELLS(i + 14, 1).Value = rs!HALNO
.CELLS(i + 14, 2).Value = rs!MÜSTAHSİLADI
.CELLS(i + 14, 3).Value = rs!ÜRÜNADI
.CELLS(i + 14, 4).Value = rs!ÜRÜNCİNSİ
.CELLS(i + 14, 5).Value = rs!NETKİLO
.CELLS(i + 14, 6).Value = rs!FİYAT
.CELLS(i + 14, 7).Value = rs!TUTAR
.CELLS(i + 14, 8).Value = rs!KDVORANI
.CELLS(i + 14, 10).Value = rs!SAHTEKÜÇÜK
.CELLS(i + 14, 11).Value = rs!SAHTEBÜYÜK
rs.MoveNext
Loop
End With
Set ExcelDosyasi = Nothing
rs.close
Murat YANDEMİR ( PyramiD YAZILIM Uluslar Arası Nakliye Programları )
Bilgisayar Programcısı (1989'dan beri)
Bilgisayar Programcısı (1989'dan beri)
Yollar biter Access bitmez.