zookeepertx
Well-known Member
- Joined
- May 27, 2011
- Messages
- 589
- Office Version
- 365
- Platform
- Windows
A while back, I needed to be able to sort really long spreadsheets by the color that the cells were. So, someone showed me to create the following function:
I would go to the first empty column to the right of my data & key in =GetColor(C7) & then autofill that down to the end of my data. This would fill the cells in that column with the number representing the color in C7 & I could then sort by that column.
Each month, I save the spreadsheet again in a new folder, for the new month's work & it has all worked perfectly for over a year! Now, suddenly, I get the error #NAME? in that column!
I wonder how one of my favorite "toys" got busted?? Can anyone help me fix it? I'll beg & grovel, if I have to, LOL!
Code:
Function GetColor(Mycell As Range)
GetColor = Mycell.Interior.ColorIndex
End Function
Each month, I save the spreadsheet again in a new folder, for the new month's work & it has all worked perfectly for over a year! Now, suddenly, I get the error #NAME? in that column!
I wonder how one of my favorite "toys" got busted?? Can anyone help me fix it? I'll beg & grovel, if I have to, LOL!