Tuesday, March 29, 2011

Excel Tip # 15: Restrict Users Free Space

Got a worksheet whose blank space you don’t want users to use for scratch work?

Open your Developer menu† (you may need to add this through Excel Options). Then paste this code into a module for the file (you may need to create one‡).

Private Sub Worksheet_Activate()

  'Set/restrict sheet's scroll area.

  Me.ScrollArea = "A1:G15"

End Sub

One drawback of this is that you will now have to save as an XLSM file, and your users will have to enable macros when they open it.

† To display the Developer Tab, click on the Office 2007 button in upper left corner, then on options, and select Developer.

‡ Click the Developer tab, then “Visual Basic”. A window will open. On the left, right-click VBAProject and choose “Insert” then “Module”. Paste the code above into the new window that opens.

Technorati Tags: ,,,,,

No comments:

Post a Comment