Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Restrictions on worksheet display
Is it possible to lock a
worksheet so that a) the user cannot move the cursor outside of a certain row range and a certain column range ? b) the use cannot change the location on the screen of the window displaying the worksheet, and he cannot change the size of the window displaying the worksheet? Thanks -- -regards |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Restrictions on worksheet display
You can protect the workbook windows and structure under
ToolsProtectionProtect Workbook to disallow resizing or moving. You can set the ScrollArea so users cannot move out of that area. Since the scrollarea method does not stick between sessions you will have to reset it each time. You may wish to place the code into a WorkBook_Open Sub in ThisWorkbook module and specify which worksheet if only one sheet required. Private Sub WorkBook_Open() Sheets("YourSheet").ScrollArea = "A1:M35" End Sub Or also in the Thisworkbook module to limit scrollarea on all sheets. Private Sub Workbook_SheetActivate(ByVal Sh As Object) With ActiveSheet .ScrollArea = "A1:M35" End With End Sub Gord Dibben MS Excel MVP On Tue, 24 Jul 2007 12:14:01 -0700, GeorgeJ wrote: Is it possible to lock a worksheet so that a) the user cannot move the cursor outside of a certain row range and a certain column range ? b) the use cannot change the location on the screen of the window displaying the worksheet, and he cannot change the size of the window displaying the worksheet? Thanks |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Restrictions on worksheet display
Thanks Gord. The stuff about scroll area was very helpful. Now suppose I
want to change back so the user can access all the cells of the sheet. What would the code be for that ? |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Restrictions on worksheet display
Assign this to a button or shortcut key.
Sub Scroll_All() Sheets("YourSheet").ScrollArea = "" End Sub Note: scrollarea will be re-set when you next open the workbook. Gord On Tue, 24 Jul 2007 15:14:06 -0700, GeorgeJ wrote: Thanks Gord. The stuff about scroll area was very helpful. Now suppose I want to change back so the user can access all the cells of the sheet. What would the code be for that ? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Text Restrictions | Excel Worksheet Functions | |||
data restrictions | Excel Discussion (Misc queries) | |||
How to add Restrictions to Combo Box?/ | Excel Worksheet Functions | |||
Field and Worksheet Restrictions | Excel Discussion (Misc queries) | |||
How to do look up with restrictions | Excel Discussion (Misc queries) |