![]() |
Auto fill color change
How do I get a cell to change the color fill automatically when specific data
is entered into a cell? I am trying yo build a calender for the company emeployees to fill out their vacation schedules. When they enter "V" into a cell, I would like that cell to automatically change to a dark blue fill with white text. -- Thanks Dave |
Sorry .... I need to expand on this thought. I figured out how to get a cell
to change for one variable with conditional formatting, however I have 5 possible variables of which I would like different colors for each. Can this be done? So for "V" I get a Dark blue fill, "H" I get another color and "A" I get another color and so on. -- Thanks Dave "Dave" wrote: How do I get a cell to change the color fill automatically when specific data is entered into a cell? I am trying yo build a calender for the company emeployees to fill out their vacation schedules. When they enter "V" into a cell, I would like that cell to automatically change to a dark blue fill with white text. -- Thanks Dave |
Hi Dave,
See the freely downloadable CFPlus addin which is freely downloadable at: http://www.xldynamic.com/source/xld.....Download.html --- Regards, Norman "Dave" wrote in message ... Sorry .... I need to expand on this thought. I figured out how to get a cell to change for one variable with conditional formatting, however I have 5 possible variables of which I would like different colors for each. Can this be done? So for "V" I get a Dark blue fill, "H" I get another color and "A" I get another color and so on. -- Thanks Dave "Dave" wrote: How do I get a cell to change the color fill automatically when specific data is entered into a cell? I am trying yo build a calender for the company emeployees to fill out their vacation schedules. When they enter "V" into a cell, I would like that cell to automatically change to a dark blue fill with white text. -- Thanks Dave |
I appreciate your quick response!! the only problem I see with this is that
everybody must have it installed in order for it to work. That isn't a possibility at work because we are not allowed to install any type of software. Is there another solution? -- Thanks Dave "Norman Jones" wrote: Hi Dave, See the freely downloadable CFPlus addin which is freely downloadable at: http://www.xldynamic.com/source/xld.....Download.html --- Regards, Norman "Dave" wrote in message ... Sorry .... I need to expand on this thought. I figured out how to get a cell to change for one variable with conditional formatting, however I have 5 possible variables of which I would like different colors for each. Can this be done? So for "V" I get a Dark blue fill, "H" I get another color and "A" I get another color and so on. -- Thanks Dave "Dave" wrote: How do I get a cell to change the color fill automatically when specific data is entered into a cell? I am trying yo build a calender for the company emeployees to fill out their vacation schedules. When they enter "V" into a cell, I would like that cell to automatically change to a dark blue fill with white text. -- Thanks Dave |
Dave
How about some VBA event code behind the worksheet? Right-click on sheet tab and "View Code". Copy/paste into that module. Adjust to suit. Option Compare Text Private Sub Worksheet_Change(ByVal Target As Range) Dim Num As Long Dim rng As Range Dim vRngInput As Variant Set vRngInput = Intersect(Target, Range("D:D")) If vRngInput Is Nothing Then Exit Sub On Error GoTo endit Application.EnableEvents = False For Each rng In vRngInput 'Determine the color Select Case rng.Value Case Is = "A": Num = 10 'green Case Is = "B": Num = 1 'black Case Is = "C": Num = 5 'blue Case Is = "D": Num = 7 'magenta Case Is = "E": Num = 46 'orange Case Is = "F": Num = 3 'red End Select 'Apply the color rng.Interior.ColorIndex = Num Next rng endit: Application.EnableEvents = True End Sub Gord Dibben Excel MVP On Tue, 14 Jun 2005 20:48:17 -0700, "Dave" wrote: I appreciate your quick response!! the only problem I see with this is that everybody must have it installed in order for it to work. That isn't a possibility at work because we are not allowed to install any type of software. Is there another solution? |
All times are GMT +1. The time now is 11:58 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com