As I wrote in my comment, the solution to your problem is to write the following:
Set hyperLinkText = hprlink.Range
Set
is needed because TextRange
is a class, so hyperLinkText
is an object; as such, if you want to assign it, you need to make it point to the actual object that you need.
More Related Contents:
- How do I get values from a hidden worksheet using VBA [closed]
- How to copy cells that contain certain text to another worksheet [closed]
- VBA Macro for copying and pasting columns on same excel sheet
- Excel VBA, code to count the # of filled cells, then find highest and 2nd highest and subtract the corresponding column #’s [closed]
- How to add default signature in Outlook
- Levenshtein Distance in VBA [closed]
- How to convert VBA script to Google Apps Script automatically?
- VBA Runtime Error 1004 “Application-defined or Object-defined error” when Selecting Range
- Assign event handlers to controls on user form created dynamically in VBA
- Programmatic Access To Visual Basic Project Is Not Trusted
- Can I make this macro more efficient or faster?
- Conditional Formatting using Excel VBA code
- Controlling IE11 “Do you want to Open/Save” dialogue window buttons in VBA
- How to get the background color from a Conditional Formatting in Excel using VBA
- VBA Excel Populate ListBox with multiple columns
- VBA Integer Overflow at 70,000
- How to count up text of a different font colour in excel
- VBA Macro to compare all cells of two Excel files
- Automate saveas dialogue for IE9 (vba)
- Sending HTTP requests with VBA from Word
- What does ReDim Preserve do?
- How to highlight a cell using the hex color value within the cell?
- How do I open an outlook .msg file from my harddrive that is NOT in outlook?
- Convert RTF (Rich Text Format) code into plain text in Excel
- lastrow and excel table.
- Exporting MS Access Forms and Class / Modules Recursively to text files?
- Repeating Microsoft Word VBA until no search results found
- Text To Clipboard in VBA Windows 10 Issue
- Excel VBA using FileSystemObject to list file last date modified
- How to have vba execute every 10 minutes?