Scroll lock problems...

Novelec

Board Regular
Joined
Nov 3, 2012
Messages
85
Hi guys,

I'm using VBA to create a scroll lock function on my worksheets.

I am finding that worksheets with hidden rows intermittently deviate from the scroll lock values specified in my code. When this happens, the difference in scroll area is usually very similar to the size of hidden rows, hence my suspicion.

Eg.

- Scroll lock is set to row 500, and no rows are hidden - I can scroll to row 500.
- Scroll lock is set to row 500, there are 50 rows hidden, I can scroll to row 450(ish).

I would have thought if anything, hidden rows would result in being able to scroll further...? Has anyone else had an issue like this before? Any suggestions as to a solution? I've attached the line of code I am using, just in case...

Thanks in advance for any assistance.

Code:
Worksheets("Sheet 1").ScrollArea = "A1:U500"
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.

Forum statistics

Threads
1,214,827
Messages
6,121,816
Members
449,049
Latest member
cybersurfer5000

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top