Outlook 2k3 Script: Creating Borders in Excel

  • Thread starter Thread starter news.microsoft.com
  • Start date Start date
N

news.microsoft.com

Hi All,

I use outlook task form to create an Excel Sheet
I fill cells with data from contact I found the why
to make text bold colored how to autofit colums to add filter

1) but I don't find the way to Add Borders....

2) I use an existing xls file to open excel how can I create a new xls
file
Sub Export_click()

Set objExcelApp = Item.Application.CreateObject("Excel.Application")

ObjExcelApp.Workbooks.Open("d:\test.xls")

Set ObjExcelBook = objExcelApp.ActiveWorkBook

Set ObjExcelSheets = objExcelBook.WorkSheets

Set ObjExcelSheet = objExcelBook.Sheets(1)



Tks
 
Excel questions are probably best asked in an Excel group, not Outlook.

That said, use WorkSheets.Add to add a new sheet. Use the Borders property
to add and set borders to a selected Range.
 
Back
Top