Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 249
Default Coverting hyperlink cell to the web page address

I have multiple hyperlinks in a document with the same name "safety
document". each calls up the webpage of the associated chemical from the
internet.

I want to convert these links to the actual web address so that I may call
up these addresses using hyperlink(vlookup etc).

Can someone help?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,316
Default Coverting hyperlink cell to the web page address

Make a back up of your file and test drive this in the spare file...

Press Alt+F11 to display the VBE and then click INSERT in the menu and
select MODULE.

Paste the following sub in the new module:

Sub ShowHLink()

Dim ws As Worksheet
Dim h As Hyperlink
Dim strHLink As String

Set ws = ThisWorkbook.Sheets(1)

For Each h In ws.Hyperlinks
h.TextToDisplay = h.Address
Next h

Set ws = Nothing
Set h = Nothing

End Sub

--
Kevin Backmann


"Roger on Excel" wrote:

I have multiple hyperlinks in a document with the same name "safety
document". each calls up the webpage of the associated chemical from the
internet.

I want to convert these links to the actual web address so that I may call
up these addresses using hyperlink(vlookup etc).

Can someone help?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,316
Default Coverting hyperlink cell to the web page address

I forgot to add the steps to running the macro:

Click TOOLS on the menu
Click MACRO on the drop-down menu
Click MACROS on the cascade menu
Select the macro named ShowHLink
Click the RUN command button


--
Kevin Backmann


"Kevin B" wrote:

Make a back up of your file and test drive this in the spare file...

Press Alt+F11 to display the VBE and then click INSERT in the menu and
select MODULE.

Paste the following sub in the new module:

Sub ShowHLink()

Dim ws As Worksheet
Dim h As Hyperlink
Dim strHLink As String

Set ws = ThisWorkbook.Sheets(1)

For Each h In ws.Hyperlinks
h.TextToDisplay = h.Address
Next h

Set ws = Nothing
Set h = Nothing

End Sub

--
Kevin Backmann


"Roger on Excel" wrote:

I have multiple hyperlinks in a document with the same name "safety
document". each calls up the webpage of the associated chemical from the
internet.

I want to convert these links to the actual web address so that I may call
up these addresses using hyperlink(vlookup etc).

Can someone help?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to extract a web address from a hyperlink cell? El Rebelde Excel Discussion (Misc queries) 2 November 16th 06 04:44 PM
Keeping the hyperlink address hidden in a cell. rholmes via OfficeKB.com Excel Worksheet Functions 7 June 17th 06 01:56 AM
How do I show the address of hyperlink to another cell in Excel ? Outlook写邮件遇到的问题 Excel Discussion (Misc queries) 1 June 7th 06 12:58 PM
How make hyperlink refer to cell content rather than cell address. Omunene Excel Discussion (Misc queries) 3 March 2nd 06 01:07 AM
how do I add a 'web address' to a cell in excel with a hyperlink? sandie white New Users to Excel 1 February 8th 06 01:30 PM


All times are GMT +1. The time now is 04:19 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright 2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"