brayleyboy
Board Regular
- Joined
- Nov 24, 2005
- Messages
- 52
Is it possible to create a dropdown list in a cell(s) whereby you can select a colour to fill the cell? I have Ecel 97 RS-2 and have been trying to do this for ages!
Private Sub Worksheet_Change(ByVal Target As Range)
MsgBox "Hello"
Dim Temp As String
On Error Resume Next
Temp = Target.Validation.Formula1
If Err <> 0 Then Exit Sub
Select Case Target.Value
Case "Red"
Target.Interior.ColorIndex = 3
Target.Font.ColorIndex = 3
Case "Green"
Target.Interior.ColorIndex = 10
Target.Font.ColorIndex = 10
Case "Blue"
Target.Interior.ColorIndex = 5
Target.Font.ColorIndex = 5
Case "Yellow"
Target.Interior.ColorIndex = 6
Target.Font.ColorIndex = 6
Case "Brown"
Target.Interior.ColorIndex = 53
Target.Font.ColorIndex = 53
End Select
End Sub