Kbase P107758: How to implement mouse events with Dynamics dynamic objects?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  7/12/2007 |
|
Status: Unverified
GOAL:
How to list the valid events for a specific object.
GOAL:
How to implement mouse events with Dynamics dynamic objects?
FACT(s) (Environment):
Dynamics
FIX:
There are differences between ADM2 events and Dynamics events. The fact is that Dynamics does not implement the events in the same way as ADM2 and as such certain events are not supported in Dynamics for dynamic objects. An example of this is the MOUSE-SELECT-DBLCLICK event.
You can check the supported events by doing something like the following from a super procedure of a dynamic browse:
DEFINE VARIABLE h_browse AS HANDLE NO-UNDO.
{get browseHandle h_browse TARGET-PROCEDURE}.
MESSAGE VALID-EVENT (h_browse,'MOUSE-SELECT-DBLCLICK') SKIP
LIST-EVENTS(h_browse).
The valid-event function will return 'No' for this event. However, you can work around the problem in the following way. In a super procedure initializeObject override of the browse:
RUN SUPER.
DEFINE VARIABLE h_browse AS HANDLE NO-UNDO.
{get browseHandle h_browse TARGET-PROCEDURE}.
ON 'MOUSE-SELECT-DBLCLICK' OF h_browse PERSISTENT RUN mouseProc IN TARGET-PROCEDURE.
This will execute the procedure 'mouseproc' whenever the double click event is triggered.