I have this piece of code in VB 6 app:
Code:
Dim xlApp
Dim xlBook
Dim xlSheet
Set xlApp = CreateObject("Excel.Application")
Set xlBook = xlApp.Workbooks.Add
Set xlSheet = xlBook.ActiveSheet
With xlApp
.Visible = True
.Range("F:F,I:I,L:L").NumberFormat = "m/d/yyyy"
.Range("J:J,M:M").NumberFormat = "$#,##0.00"
.Columns("N:N").NumberFormat = "$#,##0"
.Range("D:D,G:G,H:H,K:K").HorizontalAlignment = [highlight]xlCenter[/highlight]
End With
...
If I use early binding (use reference to Excel in VB) it works fine.
How can I allign columns in Excel with late binding?
Have fun.
---- Andy