![]() |
|
|
|
#1
|
||||
|
||||
|
Change Chr(11) to Chr(13).
or Code:
Sub Macro1()
Dim oRng As Range
Dim sLink As String
Selection.HomeKey
Set oRng = Selection.Paragraphs(1).Range
oRng.End = oRng.End - 1
sLink = oRng.Text
oRng.Hyperlinks.Add oRng, sLink
End Sub
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
|
| Tags |
| getfromclipboard, hyperlink, macro error |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Copy Specific Text String To Clipboard At End Of Macro
|
et_33 | Excel Programming | 8 | 10-11-2022 06:24 AM |
| WORD MACRO COPY/PAST from clipboard | rachidlea | Word VBA | 0 | 11-16-2021 09:38 AM |
| Macro for copying in clipboard more than one selected text | ghostwhisperer86 | Outlook | 0 | 03-31-2019 07:47 AM |
How to extract selected hyperlink address to clipboard?
|
poetofpiano | Word VBA | 8 | 02-18-2018 07:17 PM |
| Add Hyperlink in Visio that when clicked copies something to your clipboard | MoHyB | Visio | 0 | 11-10-2017 08:55 AM |