Skip to main content

[archive] Double mouse click in grid

  • November 22, 2006
  • 2 replies
  • 0 views

[Migrated content. Thread originally posted on 22 November 2006]

I want to know (whitin a grid) if someone has double clicked.
I can't find an event for this so I tried using W$MOUSE.
When I enter the event procedure I call:
W$MOUSE USING 1, MOUSE-INFO but get no result IN LBUTTON-STATUS or MBUTTON-STATUS.

I have set "MOUSE-FLAGS" to ADD-LEFT-DOUBLE and ADD-MIDDLE-DOUBLE.

Andre

2 replies

[Migrated content. Thread originally posted on 22 November 2006]

I want to know (whitin a grid) if someone has double clicked.
I can't find an event for this so I tried using W$MOUSE.
When I enter the event procedure I call:
W$MOUSE USING 1, MOUSE-INFO but get no result IN LBUTTON-STATUS or MBUTTON-STATUS.

I have set "MOUSE-FLAGS" to ADD-LEFT-DOUBLE and ADD-MIDDLE-DOUBLE.

Andre
A double-click puts the grid into entry mode. Check for this event:

MSG-BEGIN-ENTRY (value 16392)
This event occurs when the user starts modifying a cell in a grid control. EVENT-DATA-1 contains the column number of the cell, and EVENT-DATA-2 contains its record number. For convenience, the properties X and Y are set to the cursor's cell for the duration of this event (i.e., they are set to the cursor's location at entry to the event procedure and restored to their prior values at exit). This allows you to get a "before" image of the cell easily by simply doing an INQUIRE on CELL-DATA.

You can prevent the entry from occurring by setting EVENT-ACTION to EVENT-ACTION-FAIL

[Migrated content. Thread originally posted on 22 November 2006]

I want to know (whitin a grid) if someone has double clicked.
I can't find an event for this so I tried using W$MOUSE.
When I enter the event procedure I call:
W$MOUSE USING 1, MOUSE-INFO but get no result IN LBUTTON-STATUS or MBUTTON-STATUS.

I have set "MOUSE-FLAGS" to ADD-LEFT-DOUBLE and ADD-MIDDLE-DOUBLE.

Andre
Yes that's it.

Thanks!

Andre