Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Extracting Hyperlinks

I've got a Mac, OS X 10.3.9, Excel X, SR 1.

My spreadsheet has a column of values with Hyperlinks. How do I extract the
URL from the Hyperlinks and put the URL in the column to the right of the
Hyperlink?

TIA
Steve

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Extracting Hyperlinks

Hi Steven,

Try:

'=============
Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub
'<<=============

---
Regards,
Norman



"Steven Drenker" wrote in message
. ..
I've got a Mac, OS X 10.3.9, Excel X, SR 1.

My spreadsheet has a column of values with Hyperlinks. How do I extract
the
URL from the Hyperlinks and put the URL in the column to the right of the
Hyperlink?

TIA
Steve



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Extracting Hyperlinks

Hi, Norman. Thanks for the tip. Unfortunately, on my Excel Mac version, the
properties of HyperLink don't seem to be working:



Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
Debug.Print hLink.Parent.Address
Debug.Print "Hyperlink Address " & hLink.Address
Debug.Print "Hyperlink Application " & hLink.Application
Debug.Print "Hyperlink Creator " & hLink.Creator
'Debug.Print "Hyperlink EmailSubject " & hLink.EmailSubject
Debug.Print "Hyperlink Name " & hLink.Name
Debug.Print "Hyperlink Parent " & hLink.Parent
Debug.Print "Hyperlink Range " & hLink.Range
Debug.Print "Hyperlink ScreenTip " & hLink.ScreenTip
'Debug.Print "Hyperlink Shape " & hLink.Shape
Debug.Print "Hyperlink SubAddress " & hLink.SubAddress
Debug.Print "Hyperlink Type " & hLink.Type


hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub


Here are the results:
$A$1
Hyperlink Address
Hyperlink Application Microsoft Excel
Hyperlink Creator 1480803660
Hyperlink Name
Hyperlink Parent Yahoo
Hyperlink Range Yahoo
Hyperlink ScreenTip
Hyperlink SubAddress
Hyperlink Type 0

Address, Name and SubAddress properties are empty. Parent and Range
properties are wrong.

What's wrong here?

Steve

Hi Steven,

Try:

'=============
Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub
'<<=============

---
Regards,
Norman



"Steven Drenker" wrote in message
. ..
I've got a Mac, OS X 10.3.9, Excel X, SR 1.

My spreadsheet has a column of values with Hyperlinks. How do I extract
the
URL from the Hyperlinks and put the URL in the column to the right of the
Hyperlink?

TIA
Steve





  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Extracting Hyperlinks

Hi Steve,

See the following post on this subject from JE McGimpsey in the
microsoft.public.mac.office.excel group:

http://tinyurl.com/adkp9


---
Regards,
Norman


"Steven Drenker" wrote in message
...
Hi, Norman. Thanks for the tip. Unfortunately, on my Excel Mac version,
the
properties of HyperLink don't seem to be working:



Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
Debug.Print hLink.Parent.Address
Debug.Print "Hyperlink Address " & hLink.Address
Debug.Print "Hyperlink Application " & hLink.Application
Debug.Print "Hyperlink Creator " & hLink.Creator
'Debug.Print "Hyperlink EmailSubject " & hLink.EmailSubject
Debug.Print "Hyperlink Name " & hLink.Name
Debug.Print "Hyperlink Parent " & hLink.Parent
Debug.Print "Hyperlink Range " & hLink.Range
Debug.Print "Hyperlink ScreenTip " & hLink.ScreenTip
'Debug.Print "Hyperlink Shape " & hLink.Shape
Debug.Print "Hyperlink SubAddress " & hLink.SubAddress
Debug.Print "Hyperlink Type " & hLink.Type


hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub


Here are the results:
$A$1
Hyperlink Address
Hyperlink Application Microsoft Excel
Hyperlink Creator 1480803660
Hyperlink Name
Hyperlink Parent Yahoo
Hyperlink Range Yahoo
Hyperlink ScreenTip
Hyperlink SubAddress
Hyperlink Type 0

Address, Name and SubAddress properties are empty. Parent and Range
properties are wrong.

What's wrong here?

Steve

Hi Steven,

Try:

'=============
Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub
'<<=============

---
Regards,
Norman



"Steven Drenker" wrote in message
. ..
I've got a Mac, OS X 10.3.9, Excel X, SR 1.

My spreadsheet has a column of values with Hyperlinks. How do I extract
the
URL from the Hyperlinks and put the URL in the column to the right of
the
Hyperlink?

TIA
Steve







  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Extracting Hyperlinks


Hello Steve,

Try this code...

Sub ExtractURLs()

Dim Rng As Excel.Range
Dim HypLnk As Variant

For Each HypLnk In ActiveSheet.Hyperlinks
Set Rng = HypLnk.Range
Rng.Offset(0, 1).Value = HypLnk.Address
Next HypLnk

End Sub


Sincerely,
Leith Ross


--
Leith Ross
------------------------------------------------------------------------
Leith Ross's Profile: http://www.excelforum.com/member.php...o&userid=18465
View this thread: http://www.excelforum.com/showthread...hreadid=492382



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Extracting Hyperlinks

Thanks, Norman. As I suspected, it's a bug in Excel and I need to upgrade to
Excel 2004.
Steve

---------

Hi Steve,

See the following post on this subject from JE McGimpsey in the
microsoft.public.mac.office.excel group:

http://tinyurl.com/adkp9


---
Regards,
Norman


"Steven Drenker" wrote in message
...
Hi, Norman. Thanks for the tip. Unfortunately, on my Excel Mac version,
the
properties of HyperLink don't seem to be working:



Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
Debug.Print hLink.Parent.Address
Debug.Print "Hyperlink Address " & hLink.Address
Debug.Print "Hyperlink Application " & hLink.Application
Debug.Print "Hyperlink Creator " & hLink.Creator
'Debug.Print "Hyperlink EmailSubject " & hLink.EmailSubject
Debug.Print "Hyperlink Name " & hLink.Name
Debug.Print "Hyperlink Parent " & hLink.Parent
Debug.Print "Hyperlink Range " & hLink.Range
Debug.Print "Hyperlink ScreenTip " & hLink.ScreenTip
'Debug.Print "Hyperlink Shape " & hLink.Shape
Debug.Print "Hyperlink SubAddress " & hLink.SubAddress
Debug.Print "Hyperlink Type " & hLink.Type


hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub


Here are the results:
$A$1
Hyperlink Address
Hyperlink Application Microsoft Excel
Hyperlink Creator 1480803660
Hyperlink Name
Hyperlink Parent Yahoo
Hyperlink Range Yahoo
Hyperlink ScreenTip
Hyperlink SubAddress
Hyperlink Type 0

Address, Name and SubAddress properties are empty. Parent and Range
properties are wrong.

What's wrong here?

Steve

Hi Steven,

Try:

'=============
Sub Tester()
Dim rng As Range
Dim hLink As Hyperlink

For Each hLink In ActiveSheet.Hyperlinks
hLink.Parent(1, 2).Value = hLink.Address
Next hLink

End Sub
'<<=============

---
Regards,
Norman



"Steven Drenker" wrote in message
. ..
I've got a Mac, OS X 10.3.9, Excel X, SR 1.

My spreadsheet has a column of values with Hyperlinks. How do I extract
the
URL from the Hyperlinks and put the URL in the column to the right of
the
Hyperlink?

TIA
Steve








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
Update 2000 Excel hyperlinks to 2003 hyperlinks lonv155 Excel Worksheet Functions 4 October 25th 07 05:51 AM
Extracting email addresses from hyperlinks. Brossyg Excel Discussion (Misc queries) 5 May 11th 07 03:58 PM
Extracting Hyperlinks brucek Excel Discussion (Misc queries) 0 March 14th 06 02:30 PM
Extracting Hyperlinks from 4000 graphic records cfc Excel Discussion (Misc queries) 0 March 14th 06 07:04 AM
Extracting Hyperlinks Steve M[_6_] Excel Programming 4 October 25th 04 04:13 PM


All times are GMT +1. The time now is 08:20 PM.

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"