Force Hyperlinked cell to appear at top corner and sort problem

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have created a workbook with a main page where I have hyperlinks to many work sheets within the same workbook. Some hyperlinks goes to same worksheet to different cells. Problem is in such worksheets

When I click on the first hyperlink the control (focus) goes to the top left corner, but when I click on 2nd or 3rd Hyperlink for the same worksheet, the control is going to a cell displayed at the bottom left corner instead of top left corner. Is there any way I can force the hyperlinked cell to be displayed at top left corner always

When I sort the main sheet columns, I loose the Hyperlinks for some and I will have to relink. How can I avoind this

Thanks in advance
 
Hi Dev,
You can't control the behavior of the hyperlink.

You can run a macro to reposition the active cell. the macro
ShowTopLefrt is what you asked for for positioning.

'Active cell repositioned to Top also showing 5 cells to left
' remains on same sheet
Sub ShowTopLeft5()
Dim caddr As String
caddr = Selection.Address
Application.Goto Reference:=Cells(ActiveCell.Row, _
Application.WorksheetFunction _
.Max(1, ActiveCell.Column - 5)), Scroll:=True
Range(caddr).Select
End Sub

'A simpler version just makes the activecell the top left cell.
'reposition active cell to Top Left corner, remains on same sheet
Sub ShowTopLeft()
Application.Goto Reference:=Range(ActiveCell.Address), Scroll:=True
End Sub

Directions to install / use a macro can be found on my webpage
http://www.mvps.org/dmcritchie/excel/getstarted.htm
--


Dev said:
I have created a workbook with a main page where I have hyperlinks to many work sheets within the same workbook. Some hyperlinks
goes to same worksheet to different cells. Problem is in such worksheets.
When I click on the first hyperlink the control (focus) goes to the top left corner, but when I click on 2nd or 3rd Hyperlink for
the same worksheet, the control is going to a cell displayed at the bottom left corner instead of top left corner. Is there any way
I can force the hyperlinked cell to be displayed at top left corner always?
 
Back
Top