Skip to main content

Worksheet.ScrollArea property

Table of contents
  1. Syntax
  2. Remarks
  3. Example

Returns or sets the range where scrolling is allowed, as an A1-style range reference. Cells outside the scroll area cannot be selected. Read/write String.

Syntax

expression.ScrollArea

expression A variable that represents a Worksheet object.

Remarks

Set this property to the empty string ("") to enable cell selection for the entire sheet.

Example

The following example sets the scroll area for worksheet one.

Worksheets(1).ScrollArea = "a1:f10"

The following example clears the scroll area limits:

ActiveSheet.ScrollArea = ""

Leave a comment

Your email address will not be published. Required fields are marked *

Format your code: <pre><code class="language-vba">place your code here</code></pre>