Worksheet_BeforeDoubleClick event question

  • Thread starter Thread starter Barb Reinhardt
  • Start date Start date
B

Barb Reinhardt

Sometimes when I doubleclick on a cell, the cursur jumps to the cell below
the last used cell in the column. What can I do to prevent this?

Thanks,
Barb Reinhardt
 
If in Tools / Options / Edit "Edit directly in cell" is checked (left)
double click will put the cell into input mode.

Otherwise, left mouse double-click will select precedents (ie referenced
cells in the formula). If there are no precedents double click would not do
anything, assuming you don't hit the little + bottom right of the cell

Regards,
Peter T
 
Nothing that I know of. When you are directly over the cell you get the
standard cursor. When you are over the border of the active cell you get the
Move cursor (4 Arrows). Even on a double click the first click activates the
cell. If the second click is associated with the move handle then the goto
end is the standard actions and the double click is not assocated with the
cell. Since I never use the goto end feature by double clicking it is really
annoying for no particularily good reason.
 
I'm specifically using the doubleclick event to do something and this
"feature" is particularly annoying. The only way I've found around it is to
do this

Application.CellDragAndDrop = FALSE 'On WorkBook_Open

I HATE doing that, but it is what it is.

Thanks for your help.

Barb Reinhardt
 
You hit the edge of the cell.

If you're more careful with your clicking (make sure you click inside the
borders), you won't have the problem.
 
That's exactly it, but since I hit the edge of the cell about 20% of the time
once I figured out what was happening, it's not acceptable. I hate putting
in workarounds like this, but we need a doubleclick event, more than we need
the other functionality in this workbook.
 
I used to have the same problem.

I switched to de-caf and things got better <vbg>.
 
Oh great! I already drink decaf. I guess I'm up the crick! Thanks so much
for your help. <vbg back atcha>
 
Once I started watching where I clicked/doubleclicked, then it actually got
easier to get it right.

I bet you don't have the problem in a couple of days (or weeks or...)

Barb said:
Oh great! I already drink decaf. I guess I'm up the crick! Thanks so much
for your help. <vbg back atcha>
 
Figured it out... On Cell Select turn off drag and drop and use a ontime
event to turn it back on a couple of seconds later. Something like this...


Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Application.CellDragAndDrop = False
Application.OnTime Now + TimeSerial(0, 0, 3), "ResetDragAndDrop"
End Sub

Public Sub ResetDragAndDrop()
Application.CellDragAndDrop = True
End Sub

Select fires before double click. It is not ideal but you do have drag and
drop most of the time...
 
Back
Top