Hi,
I have a legend with color codes in it & no text (yet) in the cells.
I can make a drop down option or list that will "see" these colors?
Using Excel 2013
Thanks
Hi,
I have a legend with color codes in it & no text (yet) in the cells.
I can make a drop down option or list that will "see" these colors?
Using Excel 2013
Thanks
MyCon
-- Using Latest Version of Excel
Not clear what you mean by a dropdown list that can "see" colors. Can you give a more complete description of the overall problem you are trying to solve, what you want the user to see and be able to do? Are you talking about cell fill color, or text color?
The only thing I can imagine is that you want the dropdown box to be a list of the color codes shown in the legend, and also have the items in the dropdown be the same color as what is in the legend. Data Validation dropdown lists and combobox controls do not support colored background or colored text for list items. There might be some other exotic way to get there, though, if we can understand your problem better.
Hi 6StringJazzer & Others,
Yes - I thought I could use a Data Validation List Drop down option but appears that Excel does not have this option to "see" colors.
For example - My legend has:
A1 - Red cell with no text
A2 - Yellow cell with no text
A3 - Blue cell with no text
Can Excel utilize a Data Validation (drop down) list to search these cells & "see" the color schemes, then user can select need cell or color?
Thanks
No, you can't do this with data validation. Here is one way that uses VBA and a form. This is a simple example to demonstrate the technique. It assumes three cells in your legend. If you change the fill colors of the cells in the legend, the colors on the form will be updated automatically. If you double click on any cell, the form comes up and you can press the button for the desired color.
Hi 6StringJazzer
The userform is cool. How does it work?
Well, it's kind of a long explanation. In Excel, hit ALT-F11. That will open the VBA development window. You will see something like that looks like this.
Under Forms, you will see a user form. Double click on it, and you will the form itself. Right click and select View code, and you will see the code that drives the controls. The idea is that when the form is activated, it looks up the color of each cell in the legend and then sets the button color to match. Then if you push a button, it sets the color of the currently selected cell to match that color. There isn't a lot of code needed to do this.
If you know nothing at all about VBA then it's a bit difficult to give a complete course in all of this in a forum post. Let me know where you want to go from here and I'll see if I can help.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks