Scroll to rows

staticbob

Well-known Member
Joined
Oct 7, 2003
Messages
1,079
ARGHHHHHHHHHH. :x

Sorry guys, this is really bugging me now !

OK, I have a sheet, I have freeze panes activated on row 3. I then have the sheet split into 10 sections, A-Z. At the top of the page, rows 15-25, I have the titles of each section. I need these to hyperlink to the relevant section headings, and make that heading the active row below the freeze pane. This is causing me some headaches as whatever method I use, I cannot get it to actually scroll so the required row is below the sections heading, it just highlights the cell.

These are the rows associated with each section.

A - A44
B- A87
C - A111
D - A207
E - A253
F - A309
G - A340
H - A361
I - A386
J - A403

I have tried hyperlinking the titles, this doesn't work.

I have tried code that first selects a cell at the end of the sections, then selects the title, that doesn't work. And also code that selects a named range which relates to the area I need to be visible, this doesn't work.

Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
'check target column and rows
If Target.Column <> 3 Then Exit Sub
If Target.row < 15 Or Target.row > 34 Then Exit Sub
Application.EnableEvents = False
Range("C450").Select

Select Case Target.row
Case 15
Range("zpreha").Select
Range("C44").Select
Case 17
Range("C87").Select
Case 19
Range("C111").Select
Case 21
Range("C207").Select
Case 23
Range("C253").Select
Case 25
Range("C309").Select
Case 27
Range("C340").Select
Case 29
Range("C361").Select
Case 31
Range("C386").Select
Case 33
Range("C403").Select
End Select
Application.EnableEvents = True

End Sub

Does anybody have any ideas how I can accomplish this ?!? I can make the sheet available if requried.

Thanks in advance !
Bob
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.

Forum statistics

Threads
1,214,627
Messages
6,120,610
Members
448,973
Latest member
ChristineC

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