I am running the macro below automatically at opening the workbook so It always looks the same.
But when I delete the hyperlinks it changes the cell color if a hyperlink was there. Doing so manually via the mouse does not. I would like to preserve the cell colors.
any ideas?
Cells.Select
With Selection.Font
.ColorIndex = xlAutomatic
.TintAndShade = 0
End With
With Selection.Font
.Name = "Calibri Light"
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.ColorIndex = xlAutomatic
.TintAndShade = 0
.ThemeFont = xlThemeFontMajor
End With
With Selection.Font
.Name = "Calibri"
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.ColorIndex = xlAutomatic
.TintAndShade = 0
.ThemeFont = xlThemeFontMinor
End With
Selection.Hyperlinks.Delete
ActiveWindow.SmallScroll Down:=-21
Range("D5").Select
But when I delete the hyperlinks it changes the cell color if a hyperlink was there. Doing so manually via the mouse does not. I would like to preserve the cell colors.
any ideas?
Cells.Select
With Selection.Font
.ColorIndex = xlAutomatic
.TintAndShade = 0
End With
With Selection.Font
.Name = "Calibri Light"
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.ColorIndex = xlAutomatic
.TintAndShade = 0
.ThemeFont = xlThemeFontMajor
End With
With Selection.Font
.Name = "Calibri"
.Strikethrough = False
.Superscript = False
.Subscript = False
.OutlineFont = False
.Shadow = False
.ColorIndex = xlAutomatic
.TintAndShade = 0
.ThemeFont = xlThemeFontMinor
End With
Selection.Hyperlinks.Delete
ActiveWindow.SmallScroll Down:=-21
Range("D5").Select