Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

restrict scroll area

740 views
Skip to first unread message

Dave Palombo

unread,
Aug 11, 2001, 3:17:08 PM8/11/01
to
how can I restrict the scroll area -ie A1:P54

When I ener this in VBA editor at scrollarea it restrictsthe scrolling until
I quit, when I restart the saved document the scroll area is unrestrricted
again.

Thanx in Advance
Dave


Bill Manville

unread,
Aug 11, 2001, 6:50:02 PM8/11/01
to
In article <eVpYrqpIBHA.1964@tkmsftngp05>, Dave Palombo wrote:
> how can I restrict the scroll area -ie A1:P54
>
> When I ener this in VBA editor at scrollarea it restrictsthe scrolling until
> I quit, when I restart the saved document the scroll area is unrestrricted
> again.
>

ScrollArea is not saved with the workbook and needs to be set in Auto_Open
or Workbook_Open. Same goes for UserInterfaceOnly protection.

Sub Auto_Open()
With Sheets("Whichever")
.ScrollArea = Range("A1:P54")
.Protect UserInterfaceOnly:=True
End With
End Sub

Bill Manville
MVP - Microsoft Excel, Oxford, England
No email replies please - reply in newsgroup

Dave Palombo

unread,
Aug 12, 2001, 11:37:57 AM8/12/01
to
I have tried to insert this into a module in VBE to no avail...
I have tried to substitute the worksheet names in lieu of Whichever still
nothing.

Please , what am I missing here?
Thanks,
Dave


"Bill Manville" <Bill-M...@msn.com> wrote in message
news:VA.00000ab...@msn.com...

Dave Peterson

unread,
Aug 12, 2001, 1:56:51 PM8/12/01
to
Did you close and reopen your workbook.

The Auto_open Sub will fire when you first open your workbook.

By chance, are you controlling this workbook from another workbook?

--

Dave Peterson
ec3...@msn.com

Bill Manville

unread,
Aug 12, 2001, 6:32:32 PM8/12/01
to
In article <uJ6MZb0IBHA.1732@tkmsftngp03>, Dave Palombo wrote:
> I have tried to insert this into a module in VBE to no avail...
> I have tried to substitute the worksheet names in lieu of Whichever still
> nothing.
>

As Dave rightly points out, you need to run the macro - either explicitly or by
opening the workbook.
Also, make sure the Auto_Open procedure is in a standard module (not in one of
the "Excel Objects'" modules

0 new messages