Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
jswafa
 
Posts: n/a
Default Associate name with email

I have a column of names and a column of email addresses. Is there any way
to merger them into a single hyperlink that shows the name and sends to the
email address?
  #2   Report Post  
Ron de Bruin
 
Posts: n/a
Default

Hi jswafa

Try this : With the names in column A and the E-mail addresses in column B try this

Sub test()
For Each myCell In Columns("B").Cells.SpecialCells(xlCellTypeConstant s)
If myCell.Value Like "?*@?*.?*" Then
ActiveSheet.Hyperlinks.Add Anchor:=myCell.Offset(0, -1), _
Address:="mailto:" & myCell.Value, TextToDisplay:=myCell.Offset(0, -1).Value
End If
Next
End Sub


--
Regards Ron de Bruin
http://www.rondebruin.nl



"jswafa" wrote in message ...
I have a column of names and a column of email addresses. Is there any way
to merger them into a single hyperlink that shows the name and sends to the
email address?



  #3   Report Post  
jswafa
 
Posts: n/a
Default

Worked great, Ron - thanks for the tip!

"Ron de Bruin" wrote:

Hi jswafa

Try this : With the names in column A and the E-mail addresses in column B try this

Sub test()
For Each myCell In Columns("B").Cells.SpecialCells(xlCellTypeConstant s)
If myCell.Value Like "?*@?*.?*" Then
ActiveSheet.Hyperlinks.Add Anchor:=myCell.Offset(0, -1), _
Address:="mailto:" & myCell.Value, TextToDisplay:=myCell.Offset(0, -1).Value
End If
Next
End Sub


--
Regards Ron de Bruin
http://www.rondebruin.nl



"jswafa" wrote in message ...
I have a column of names and a column of email addresses. Is there any way
to merger them into a single hyperlink that shows the name and sends to the
email address?




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
body of email disappears when I send an email from Excel ~A Excel Discussion (Misc queries) 0 February 25th 05 10:55 PM
Activate email column to hyperlinks DixieWins Excel Discussion (Misc queries) 2 February 3rd 05 08:09 PM
Help me Please!! Need hyperlinks to show actual email address! dustin New Users to Excel 1 January 13th 05 08:59 PM
Shut off email address from linking to email program? Java Jake Excel Worksheet Functions 6 December 31st 04 04:05 PM
How do I include cell data in subject line of email address/hyperl gvinnola Excel Worksheet Functions 1 November 18th 04 02:36 AM


All times are GMT +1. The time now is 07:16 PM.

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

About Us

"It's about Microsoft Excel"