Hi,
You can either use auto formatting technique or you can do it you self from code behind.
For auto formatting the excel sheet check the below link
Do it your self from Code Behind
Imports Excel = Microsoft.Office.Interop.Excel
Dim xlWorkSheetToUpload As Excel.Worksheet
xlWorkSheetToUpload = xlAppToUpload.Sheets("Sheet1")
With xlWorkSheet
.Cells(1, 1).value = "Company Name"
.Cells(1, 1).FONT.NAME = "Calibri"
.Cells(1, 1).Font.Bold = True
.Cells(3, 1).value = "Date & Time:"
.Cells(3, 1).FONT.NAME = "Calibri"
.Cells(3, 3).value = Date.Now
.Cells(3, 3).FONT.NAME = "Calibri"
.Cells(3, 3).Font.Bold = True
' MERGE THE CELLS.
.Range("B3:C3").MergeCells = True
end with
Rimi
Oswaldlily, if this helps please login to Mark As Answer. | Alert Moderator