View Single Post
  #1   Report Post  
Nimbus55
 
Posts: n/a
Default

Thank you....it's perfect!

"JE McGimpsey" wrote:

Forgot to say that this should go in your worksheet code module
(right-click the worksheet tab and choose View Code)

In article ,
JE McGimpsey wrote:

Would you settle for a double-click?

Private Sub Worksheet_BeforeDoubleClick( _
ByVal Target As Excel.Range, Cancel As Boolean)
Cancel = True
With Target.Interior
.ColorIndex = IIf(.ColorIndex = 3, xlColorIndexNone, 3)
End With
End Sub

You could do the same thing with a single click by using the
Worksheet_SelectionChange() event macro, but that would also be
triggered by tabbing, the Enter and arrow keys, etc.