Microsoft
Software
Hardware
Network
Question : Excel - Lock header and Anchor tag link to drop down list
Hi experts,
I have an Excel sheet.
Can you please explain how can I do the following:
1. Need to lock to top part of the sheet where my logo is
2. I need a drop down list (combobox) with a list of all the headings on the page.
When the user select an item in the drop down the sheet must jump to the selected heading, autoscroll.
Basically like an anchor tag in HTML for those who have HTML knowledge.
Please explain step by step as I am not very good in Excel or VB script.
Thanks in advance!
Answer : Excel - Lock header and Anchor tag link to drop down list
Marius0188:
I created an example of how this might work and saved it to my web site.
http://www.xlvbawiz.com/ee
/Q_2241618
2.xls
- Freeze the Panes
- I like to create another tab for my drop-down boxes and call it Control
- This tab can be hidden
- Enter your headings
- Highlight them and name the range (I named mine JumpTo
- Select the cell where you want to put the drop-down and select the menu Data>Validation
- Select Allow: List
- Set the Source: =JumpTo or the name of your range of headings
- Right-click on the Sheet tab and select View Code
- Copy the following code and paste it into the blank module to the right
Private Sub Worksheet_Change(ByVal Target As Range)
With Me
If Intersect(Target, .[B2]) Is Nothing Then Exit Sub
Dim oFind As Object
Set oFind = .[A:A].Find(What:=.[B2], LookAt:=xlWhole)
If Not oFind Is Nothing Then oFind.Select
End With
Set oFind = Nothing
End Sub
- Be sure to change the .[B2] to the cell where you have your Drop-down validation
That should get you started. Please let me know if you have any questions.
Kindest Regards,
Jaes
Random Solutions
Missing Menu bar in MS Word 2000
no value for Real Data Source Name, cannot perform jndi
Postscript printer driver in Adobe Readers causes blank pages to be skipped when printing
I can no longer access the SBS websites such as companyweb, owa, etc,
Custom Folder Redirection Admin Template
using the bash sort command, now do I sort dates ?
Fastest/Best Method of Parsing Data with AJAX
Firewall
how to vaidate xml data within oracle table column
SQL DATETIME Compare HELP