View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Changing a Macro

Sub convertToHypers()
Dim convertRng As Range
'Set convertRng = Range("L2:L1444")
Set convertRng = Selection
Dim rng As Range

For Each rng In convertRng
If rng.Value < "" Then
ActiveSheet.Hyperlinks.Add rng, "mailto:" & rng.Value
End If
Next rng

End Sub

--
Regards,
Tom Ogilvy


"Michael Koerner" wrote in message
...
I received this macro awhile back. It works as advertised for the most

part.
Unless the data to be converted is in a column other than "L".

What do I need to change to define the convertRng as the range I have

selected?


Sub convertToHypers()
Dim convertRng As Range
Set convertRng = Range("L2:L1444")
Dim rng As Range

For Each rng In convertRng
If rng.Value < "" Then
ActiveSheet.Hyperlinks.Add rng, "mailto:" & rng.Value
End If
Next rng

End Sub


--

Regards
Michael Koerner