Excel /VBA - Delete hyperlinks (All versions)

March 2017



A simplemethod to remove all hyperlinks in a selected range:
1 - Open the Excel workbook
2 - Press ALT + F11 (the Visual Basic Editor window opens)
3 - Insert / Module
4 - In the module copy and paste this code:
Sub EraseLinks()
With Selection
    .Hyperlinks.Delete
End With
End Sub

5 - Close the Visual Basic window to return to the sheet,
6 - Select the range containing all the links,
7 - Press ALT + F8 > select Sub EraseLinks and click on Run.

Related


Published by jak58.
This document, titled "Excel /VBA - Delete hyperlinks (All versions)," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (ccm.net).