-----------------
'new the excel application
ExlApp = New Excel.Application
ExlApp.Visible = True
'create the sheet
WSheet = ExlApp.Workbooks.Add.Worksheets.Add
Dim i, j As Integer
'fill the cells
For i = 1 To 10
For j = 1 To 10
WSheet.Cells(i, j) = i * j
Next
Next
'format the cells
For i = 1 To 10
For j = 1 To 10
If i Mod 2 = 0 And j Mod 2 = 0 Then
WSheet.Cells(i, j).Select()
ExlApp.Selection.font.color = Color.Red
End If
Next
Next