format cell to change color when copied

T

tawnee jamison

I do alot of cut and pasting. Is there a code that will change the color
of a cell if I right click to copy it, so I can track what I have worked
on?

Thanks, Tawnee
 
G

Gord Dibben

Tawnee

Can be done, but you'll soon end up not knowing which was which.

Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, _
Cancel As Boolean)
If Target.Cells.Count > 1 Then Exit Sub
If Intersect(Target, Me.Range("A1:A10")) Is Nothing Then Exit Sub
'adjust the Range to your needs
On Error GoTo CleanUp
Application.EnableEvents = False
Target.Interior.ColorIndex = 3
CleanUp:
Application.EnableEvents = True
End Sub


Gord Dibben Excel MVP
 
Top