T
Tai-Pan
Hi,
I am trying to remove all of the hyperlinks in my (giant 100 meg) work
book or any subset of the workbook, but everything I have tried has
failed.
I can right click on each cell and remove the link, but that will take
weeks.
I tried the following:
1) Multiply a selection by 1. This does not work. I can multiply a
single cell by one, but if I do a selection, it does not work.
2)*This crashes my workbook*
Sub DeleteHyper()
ActiveSheet.Hyperlinks.Delete
End Sub
3) *Again, this does not work if I select more than on cell at a time*
Sub DeleteHyper()
selection.Hyperlinks.Delete
End Sub
4) *This crashes excel. I got this off of MS's site and it was
supposed to select all the cells with a hyperlink*
'This Sub procedure selects all cells in the worksheet that contain
'hyperlinks. You can then clear the selected cells to delete all of
'the hyperlinks.
Sub SelectAllHyperlinkCells()
FirstCell = 1
For Each xLink In ActiveSheet.Hyperlinks
If FirstCell = 1 Then
Set xRange = xLink.Range
FirstCell = 0
Else
Set xRange = Application.Union(xRange, xLink.Range)
End If
Next xLink
xRange.Select
End Sub
I am wondering if my copy of excel has been corrupted somehow since all
of these things that "should" work just don't. I tried working with a
single tab and moving it out of the workbook, but that had no effect.
Thanks for any advice!
I am trying to remove all of the hyperlinks in my (giant 100 meg) work
book or any subset of the workbook, but everything I have tried has
failed.
I can right click on each cell and remove the link, but that will take
weeks.
I tried the following:
1) Multiply a selection by 1. This does not work. I can multiply a
single cell by one, but if I do a selection, it does not work.
2)*This crashes my workbook*
Sub DeleteHyper()
ActiveSheet.Hyperlinks.Delete
End Sub
3) *Again, this does not work if I select more than on cell at a time*
Sub DeleteHyper()
selection.Hyperlinks.Delete
End Sub
4) *This crashes excel. I got this off of MS's site and it was
supposed to select all the cells with a hyperlink*
'This Sub procedure selects all cells in the worksheet that contain
'hyperlinks. You can then clear the selected cells to delete all of
'the hyperlinks.
Sub SelectAllHyperlinkCells()
FirstCell = 1
For Each xLink In ActiveSheet.Hyperlinks
If FirstCell = 1 Then
Set xRange = xLink.Range
FirstCell = 0
Else
Set xRange = Application.Union(xRange, xLink.Range)
End If
Next xLink
xRange.Select
End Sub
I am wondering if my copy of excel has been corrupted somehow since all
of these things that "should" work just don't. I tried working with a
single tab and moving it out of the workbook, but that had no effect.
Thanks for any advice!