transferring hyperlinks across cells

jonnyw74

New Member
Joined
Apr 7, 2002
Messages
2
I have a document list on one worksheet which are hyperlinked. (150 docs)
I have another worksheet using formula to extract these documents into a shorter list but the hyperlink is not brought across, only the text.
Is there a piece of code,formula or format command to make the hyperlink copy across.
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
Hi Jonnyw74,

Hyperlinks cannot be set by formulas or worksheet functions. There is a HYPERLINK worksheet function that enables following a hyperlink, but I do not believe this is what you want. Fortunately, it is quite easy to copy hyperlinks in VBA. The following line of code will copy a hyperlink from one cell to another. In this case from cell B4 on Sheet1 to cell A2 on Sheet2.

Sheet2.Hyperlinks.Add Sheet2.[a2], Sheet1.[b4].Hyperlinks(1).Address

If this example is not specific enough to your problem feel free to follow up.
 
Upvote 0

Forum statistics

Threads
1,215,220
Messages
6,123,694
Members
449,117
Latest member
Aaagu

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