Excel Macro
Here are some other things you can do within the Excel Macro.
Where ws is the worksheet, this will active the freezepane functionality.
ws.Application.ActiveWindow.SplitRow = 1
ws.Application.ActiveWindow.FreezePanes = True
To change functionality on the printer, you can do something like this.
'Printer Setup
ws.PageSetup.PrintGridlines = True
ws.PageSetup.PrintHeadings = True
ws.PageSetup.Orientation = xlLandscape
ws.PageSetup.CenterFooter = "Page &P of &N"
ws.Cells.ColumnWidth = 10
To clear the worksheet, you can do something like this.
ws.Rows.Clear
ws.Rows.ClearContents
ws.Rows.ClearFormats
ws.Rows.ClearComments

0 comments:
Post a Comment