ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Scroll problem in Excel sheet (https://www.excelbanter.com/excel-discussion-misc-queries/136089-scroll-problem-excel-sheet.html)

Ravi Garg

Scroll problem in Excel sheet
 
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

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


All times are GMT +1. The time now is 10:36 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com