断开所有超链接

Posted sundances

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了断开所有超链接相关的知识,希望对你有一定的参考价值。

Sub BreakAllLinks(wb As Workbook)
Dim links As Variant
With wb
    links = .LinkSources(xlLinkTypeExcelLinks)
    If Not IsEmpty(links) Then
        For i = 1 To UBound(links)
            .BreakLink Name:=links(i), Type:=xlLinkTypeExcelLinks
        Next
    End If
    links = .LinkSources(xlLinkTypeOLELinks)
    If Not IsEmpty(links) Then
        For i = 1 To UBound(links)
            .BreakLink Name:=links(i), Type:=xlLinkTypeOLELinks
        Next
    End If
End With
End Sub

 

以上是关于断开所有超链接的主要内容,如果未能解决你的问题,请参考以下文章

HTML代码片段

微信小程序代码片段

添加超链接时,VBA抛出错误1004

超实用的php代码片段

十个html5代码片段,超实用,一定要收藏

jQuery 预先添加到链接到 PDF 文件的所有超链接元素