![]() |
Shade cells with links to external workbooks
Hello. I am trying to write code that will scan every sheet within a
workbook and shade each cell that has a link to an external file (ie .xls)? I am only concerned about cells, not named ranges, pictures, etc... Thanks! |
Shade cells with links to external workbooks
ActiveSheet.UsedRange.Interior.ColorIndex = xlNone
for each cell in Activesheet.UsedRange.SpecialCells(xlFormulas) if instr(1,cell.Formula,"[",vbTextcompare) Then cell.Interior.ColorIndex = 3 end if Next -- Regards, Tom Ogilvy "Steph" wrote in message ... Hello. I am trying to write code that will scan every sheet within a workbook and shade each cell that has a link to an external file (ie ..xls)? I am only concerned about cells, not named ranges, pictures, etc... Thanks! |
Shade cells with links to external workbooks
Thanks Tom!
"Tom Ogilvy" wrote in message ... ActiveSheet.UsedRange.Interior.ColorIndex = xlNone for each cell in Activesheet.UsedRange.SpecialCells(xlFormulas) if instr(1,cell.Formula,"[",vbTextcompare) Then cell.Interior.ColorIndex = 3 end if Next -- Regards, Tom Ogilvy "Steph" wrote in message ... Hello. I am trying to write code that will scan every sheet within a workbook and shade each cell that has a link to an external file (ie .xls)? I am only concerned about cells, not named ranges, pictures, etc... Thanks! |
All times are GMT +1. The time now is 02:45 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com