Mike
The code must be pasted in the Thisworkbook module, not a general module.
ALT + F11 to open VBE.
CTRL + r to open Project Explorer.
Select and expand your workbook/project.
Click on Microsoft Excel Objects.
Double-click on Thisworkbook to open.
Paste the code in there. "YourSheet" must be changed to whatever sheetname is
appropriate.
Save and close the file.
Re-open and scrollarea should be set.
Gord
On Wed, 20 Apr 2005 06:15:02 -0700, "Mike"
wrote:
I have gone to VB and copied your code below but to no avail. Could you
explain again in perhpas simpler terms in case I've missed something ? thanks
"Gord Dibben" wrote:
bek
Select all columns right of F and FormatColumnHide.
Same for rows below your data.
OR FormatCellsPatterns. Pick a nice gray color.
Alternative to the above........
Set the Scroll Area so's no one can move out of the area you designate.
Note: Setting ScrollArea is good for that session only and only the
activesheet. Has to be reset next time workbook is opened.
Best to place the code into a WorkBook_Open Sub in ThisWorkbook module and
specify which worksheet.
Private Sub WorkBook_Open()
Sheets("YourSheet").ScrollArea = "A1:F50"
End Sub
Gord Dibben Excel MVP
On Wed, 2 Mar 2005 13:29:09 -0800, bekwud
wrote:
i have created a spreadsheet which only uses columns a-f. i would like to
crop this area or remove g onwards so g onwards is completely blank or a grey
area. any ideas? i can't find anything in the search for help database b ut i
know it can be done as i have seen other workbooks the same. thanx for your
time if you reply i appreciate it :O)