change default font color for editing/review

A

AJB

I want to be able to write a macro to make red the default font color upon
command to be able to clearly see edits & changes, but I can't seem to be
able to do it. Clicking on Tools/Options/Colors doesn't change my font
color. I want to be able to click in any cell, write, and have it be red.
Any suggestions? Thanks.
 
A

AJB

My question may have been unclear. I want to avoid have to change the font
for each edited cell to red separately. The desired outcome is being able to
click any cell, and what you write is in red without having to manually
switch from the default, black.
 
G

Gord Dibben

Any cell or a particular range of cells?

You could use worksheet event code that would turn the font red as you entered
something.

As written the code below acts upon any cell into which you enter something.

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo ws_exit:
Application.EnableEvents = False
With Target
If .Value <> "" Then
.Font.ColorIndex = 3
End If
End With
ws_exit:
Application.EnableEvents = True
End Sub

This is sheet event code. Right-click on the sheet tab and "View Code"

Copy/paste into that sheet module.


Gord Dibben MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top