Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Remove Hyperlinks Without Changing background shading
I have many workbooks and sheets that I need to remove the hyperlinks from.
When doing the code below, it removes all formatting. Sub RemoveHyperlinks() Selection.Hyperlinks().Delete End Sub The issue is that it changes all the fonts boarders and many of the cells have different color background shadings (fill). So I turned the "Record Macro" on and was able to modify the Macro by reapplying the font name, font size, font color, cell boarders. Sub RemoveHyperlinksOnly() Selection.Hyperlinks().Delete ' Set new font name --code-- ' Set new font size --code-- ' Set new font color --code-- ' Set boarders --code-- End Sub However, the "Format CellFillColor" of many cells are Green, Red, Yellow & Pink I know I can use format painter and do these separately but I have many of these to do on an ongoing basis. The Excel Workbooks are given to me so I have to make the changes to 8-12 sheets out of 15 sheets total. I need a way to add to my existing macro to take a cell and do the following: Sub RemoveHyperlinksOnly() 1 store existing "Format CellFillColor" in a variable 2 do my existing macro 3 change "Format CellFillColor" to the variable that was stored End Sub Any help is appreciated. I suspect it is easy to do but I don't deal with macros much. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2003 bank ledger spreadsheet background fill shading | Excel Worksheet Functions | |||
How do I fix the background shading by position? | Excel Discussion (Misc queries) | |||
Excel Background Shading | Excel Discussion (Misc queries) | |||
Restoring Excel gridlines after removing background shading? | Excel Discussion (Misc queries) | |||
Background Cell shading colors | Excel Programming |