📊 VBA (Excel)

Remove Hyperlinks from Sheet

Strips all hyperlinks from the active sheet while keeping the cell text and formatting intact.

By WindowsScripting.com · 323 B
RemoveHyperlinksFromSheet.bas
Attribute VB_Name = "RemoveHyperlinksFromSheet"
Option Explicit

Public Sub RemoveHyperlinksFromSheet()
    Dim ws As Worksheet
    Dim count As Long

    Set ws = ActiveSheet
    count = ws.Hyperlinks.Count
    ws.Hyperlinks.Delete

    MsgBox count & " hyperlink(s) removed from '" & ws.Name & "'.", vbInformation
End Sub