Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
how can i change colour of a cell
on excel, how can you change the colour of a cell by putting a value in
another cell |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
how can i change colour of a cell
Conditional Formatting on the Format menu can do this. First, select
the cell whose color should change. Then, open the Conditional Formatting dialog from the Format menu. There, change "Cell Value Is" to "Formula Is" and enter something like the following in the formula box: =A110 Change that formula to return TRUE or FALSE, indicating whether the format should be applied. Then click the Format button and choose the Pattern tab. Select the color to fill the cell. Click OK until you're done. If the formula is TRUE (e.g., A110), the format you selected will be applied to the cell. If the formula is FALSE, no format (other than the cell's default format) will be applied to the cell. Cordially, Chip Pearson Microsoft Most Valuable Professional Excel Product Group, 1998 - 2009 Pearson Software Consulting, LLC www.cpearson.com (email on web site) On Wed, 20 May 2009 13:56:01 -0700, lee wrote: on excel, how can you change the colour of a cell by putting a value in another cell |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
how can i change colour of a cell
put this code in the sheet's code page (right click the tab & click View
Code) Option Explicit Private Sub Worksheet_Change(ByVal Target As Range) ' cell D4 triggers a colr change in E4 If Target.Address = "$D$4" Then If IsNumeric(Target.Value) Then Select Case Target.Value Case 1 To 56 Range("E4").Interior.ColorIndex = Target.Value Case Else End Select End If End If End Sub to see all available colors, put this code into a standard module Option Explicit Sub ListColors() Dim i As Long On Error GoTo Quit i = 1 Do Cells(i, 1) = i Cells(i, 2).Interior.ColorIndex = i i = i + 1 Loop Quit: End Sub "lee" wrote in message ... on excel, how can you change the colour of a cell by putting a value in another cell |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Change cell colour on formula result change, no conditional format | Excel Programming | |||
Change cell colour to red | Excel Programming | |||
if cell colour is then change cell colour in range | Excel Programming | |||
change a cell background colour to my own RGB colour requirements | Excel Discussion (Misc queries) | |||
COLOUR CHANGE IS A CELL | Excel Discussion (Misc queries) |