Change the background color of cells once it being edited

  • Thread starter Thread starter shawn lee
  • Start date Start date
S

shawn lee

Hi all, wondering if you all have any solutions for changing the
background color of cells once its being edited .

For example, I have a monthly report in excel for the month of August.
Then when it comes to September, I will need to do some changes to it.
The macro will run and color the cell background to all those cells
that are edited (different from August).

Then in October, the same thing happens again. Any bright ideas?
 
Hi

You can try like the following

Private Sub Worksheet_Change(ByVal Target As Range)
Target.Interior.ColorIndex = 35
End Sub

Cheers
Shasur
 
Hi,

It works, but what I want is when some changes is made then it change
the cell background color. For this code, if for example the original
value in the cell is 1 then if you type 1 into the cell again, it
changes color.

Do you have something where by if you key 1 in it, it wont change color
but when you key something else maybe 2 or 100 then it changes color.

Anyway its already a big step forward. Thanks dude
 
Back
Top