excel vbe scroll range - how to save?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Tools -> Macro -> VBE
VBE, Properties Window, Scroll Area
Ok, I set Scroll Area A1:B164, save and return to Excel spreadsheet.
Data entry works fine, cursor jumps from A1 -> B1, and down to line 2, A2 ->
B2, etc
Save spreadsheet, and exit.
When loading same spreadsheet, the ScrollArea is blank.
How do I save this feature?
 
Sorry Bob I thought that the scroll area saved with the worksheet but it
needs to be set when the book is opened... To the thisworkbook module (double
click on it in project explorer) add

Private Sub Workbook_Open()
Sheet1.ScrollArea = "A1:B164" 'or whetever sheet you need
End Sub

Macros must be enabled for this to work or the project digitally signed...
 
That did it.
One minor addition. Suppose I want just one more cell active, to enter new
report date manually? Is it possible to have two ranges? c2 and a4:b164 or
even a1, a4:b164

If not thanks a lot, scroll and save a1.b164 work well enough
 
Back
Top