Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I would like VBA to insert hyperlink into cell A50 & below for every part
number contained in B1:Z1 .. When the hyperlinks are available in column A, users no longer need to scroll through B1:Z1 in search of part numbers. Ive tried recording macro for hyperlink but cant seem to understand how to modify it. My modifications kept returning error, hence, needing your sample. Thanks a lot -- Edmund (Using Excel XP) |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hello Edmund, Here is the macro to "bookmark" your parts on the worksheet. Change th Worksheet name (its commented in the code) to whatever the name of you worksheet is. The example assumes Sheet1. Code ------------------- Sub BookmarkParts() Dim LinkCell As Range Dim PartCell As Range Dim Wks As Worksheet 'Put your worksheet name inside the quotes Set Wks = Worksheets("Sheet1") For Each PartCell In Wks.Range("B1:Z1") I = I + 1 With Wks Set LinkCell = .Cells(I, "A") .Hyperlinks.Add Anchor:=LinkCell, Address:="", SubAddress:=PartCell.Address, TextToDisplay:=PartCell.Value End With Next PartCell End Sub ------------------- Sincerely, Leith Ros -- Leith Ros ----------------------------------------------------------------------- Leith Ross's Profile: http://www.excelforum.com/member.php...fo&userid=1846 View this thread: http://www.excelforum.com/showthread.php?threadid=55798 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Can't make hyperlink function work for hyperlink to website | Excel Worksheet Functions | |||
Moving rows with Hyperlink doesn't move hyperlink address | Excel Discussion (Misc queries) | |||
Intra-workbook hyperlink: macro/function to return to hyperlink ce | Excel Discussion (Misc queries) | |||
Macro to Copy Hyperlink to another file as a HYPERLINK, not text... | Excel Programming | |||
reading html when hyperlink address not hyperlink text diplayed | Excel Programming |