View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Two double click events?

just an added thought.

Unless by replace Jim's code you mean his original post in the original
thread rather than his post in this thread whch seems almost identical to
yours.

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As
Boolean)
Cancel = True
If Target.Row = 1 Then
Target.Value = Date
Else
Select Case Target.Value
Case Empty
Target.Value = "x"
Case "x"
Target.Value = "xx"
Case "xx"
Target.Value = 15
Case 15
Target.Value = "I'm calling your mom"
End Select
End If
End Sub

--
Regards,
Tom Ogilvy

"GS" wrote in message
...
Thanks for noticing, Tom!
I didn't remove it, ..I stopped typing to copy/paste so I guess I omitted
it. There is no significance or merit in removing it!

Regards,
GS

"Tom Ogilvy" wrote:

Why. I don't see any merit in removing VALUE. What is the

significance.

--
Regards,
Tom Ogilvy

"GS" wrote in message
...
Hi,

Revise Jim's code as follows:

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel

As
Boolean)

Cancel = True
If Target.Row = 1 Then
Target = Date
Else
Select Case Target
Case Empty
Target.Value = "x"
Case "x"
Target.Value = "xx"
Case "xx"
Target.Value = 15
End Select
End If

End Sub

Regards,
GS

"PG Oriel" wrote:

Hi...

I have been given some advice to use a double click event to change

my
cells
contents which works brilliantly.

Is there a way to get another double click event to work for some

specific
cells in the same sheet's code? Such as the inserting the day's date

into a
cell in the top row when I double click? ... Whilst ensuring the

remaining
cells do another double click event??

Thanks.