Solved: Change a Picture or Object Color using cell values
I need to create a map and change the colors of the individual states based on cell values.
I was thinking of have 50 individual pictures/shapes/objects/whatever (1 for each state) and then use VBA to change the color of the individulas items.
If I remember tomorrow, I will see if I have an example that I did a year or two back. I added some code to make it fit my needs that you might like as well.
Yes, that is the right decimal value for blue. Perhaps my colorindex chart will help.
Attached is my example map. It has some other little goodies in it like a colorpicker dialog using John Walkenbach's code. One could easily add a Selection event to set color interiors and values in the Data sheet.
Change the color values in column G on the Data sheet and run UpdateMap() in the Module mMap to update the map.
The shapes could probably be moved a bit to look better. Of course the shape colors can be changed manually easily enough.