Skip to main content

AccessTr.neT


Access İle Excel Hücresi Biçimlendirme

Access İle Excel Hücresi Biçimlendirme

#10
Dim xlApp As Excel.Application
Dim xlSh As Excel.Worksheet
Dim objWkb As Excel.Workbook
Set xlApp = New Excel.Application

xlApp.Visible = True
Set objWkb = xlApp.Workbooks.Add

With xlApp.Sheets(1)
    Set Rng = .Range("B2:H" & Me.Liste5.ListCount + 1)
End With

Rng.Borders.Weight = 2

With Rng.Borders(7)
    .LineStyle = 1
    .ColorIndex = 0
    .TintAndShade = 0
    .Weight = 3
End With
With Rng.Borders(8)
    .LineStyle = 1
    .ColorIndex = 0
    .TintAndShade = 0
    .Weight = 3
End With
With Rng.Borders(9)
    .LineStyle = 1
    .ColorIndex = 0
    .TintAndShade = 0
    .Weight = 3
End With
With Rng.Borders(10)
    .LineStyle = 1
    .ColorIndex = 0
    .TintAndShade = 0
    .Weight = 3
End With

For i = 0 To Me.Liste5.ListCount - 1

xlApp.Sheets(1).Cells(i + 2, 2).Value = Me.Liste5.Column(0, i)
xlApp.Sheets(1).Cells(i + 2, 3).Value = Me.Liste5.Column(1, i)
xlApp.Sheets(1).Cells(i + 2, 4).Value = Me.Liste5.Column(2, i)
xlApp.Sheets(1).Cells(i + 2, 5).Value = Me.Liste5.Column(3, i)
xlApp.Sheets(1).Cells(i + 2, 6).Value = Me.Liste5.Column(4, i)
xlApp.Sheets(1).Cells(i + 2, 7).Value = Me.Liste5.Column(5, i)
xlApp.Sheets(1).Cells(i + 2, 8).Value = Me.Liste5.Column(6, i)

Next i

xlApp.Sheets(1).Range("B1").Select
xlApp.Sheets(1).Range("B1").ColumnWidth = "40"
Cevapla

Bir hesap oluşturun veya yorum yapmak için giriş yapın

Yorum yapmak için üye olmanız gerekiyor

ya da

Bu Konudaki Yorumlar
Cvp: excel - Yazar: berduş - 18/12/2019, 13:34
Cvp: excel - Yazar: zaferlacin - 18/12/2019, 18:34
Cvp: excel - Yazar: zaferlacin - 19/12/2019, 13:41
Cvp: Access İle Excel Hücresi Biçimlendirme - Yazar: ozanakkaya - 19/12/2019, 16:00
Task