View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Scroll problem in Excel sheet

You could hide rows/columns so that the user can't even see them.

Or you could set the ScrollArea to be what you want--each time you open the
workbook:

Option Explicit
Sub auto_open()
With Worksheets("sheet1")
.Protect Password:="hi"
' .EnableSelection = xlUnlockedCells
.ScrollArea = .Range("a1:f22").Address
End With
End Sub

Excel won't remember these settings after you close it and reopen the workbook
(that's why it's in auto_open).

If you want to keep the users from selecting locked cells, too, then uncomment
that line in the middle.

Ravi Garg wrote:

In one of worksheet, the sheet is protected. Locked cells can not be selected.
I have freezed the row and column both. At the extreme left and right
columns of sheet are locked, therfore cant be selected.
Sheet size is more than one screen. Now when I scroll from left to right
thru arrow keys, the scroll restarts automatically from the first selectable
column on screen-1, when it reaches at thelast selectable column on
subsequent screens.

How to stop the scroll when at the last selectable column?
Can anybody plz help me?
Thanks in advance.


--

Dave Peterson