I'd like to create a macro that goes through the whole range (which is one column). The Hyperlink needs to be created depending on the cell's value, which is always a link to one of my folders on the computer. (for example: "C:\Users\me\workstuff")
I'm not even familiar with VBA - Hyperlink relations, so I don't know where to start.
Thanks for any future suggestions!
Sub linker()
Dim ws As Worksheet
Worksheets("2023").Select
Range("J:J").Select
For Each Cell In Range
ActiveCell.Hyperlinks.Add Anchor:=Selection, Address:="", SubAddress:="", TextToDisplay:="Link to the files"
End Sub
CodePudding user response:
Do you really need VBA for this? There's an excellent HYPERLINK
formula to use :