4D View v14

PV Get on event method

Home

 
4D View v14
PV Get on event method

PV Get on event method 


 

PV Get on event method ( area ; event ) -> Function result 
Parameter Type   Description
area  Longint in 4D View area
event  Longint in 4D View event
Function result  String in 4D method name

The PV Get on event method command returns the name of the method linked with the specified event callback.

The PV Event constants are used to define the event :

Constant Type Value
pv on active cell changed Longint 8
pv on cell value changed Longint 9
pv on clicked Longint 2
pv on column resize Longint 12
pv on column sort Longint 14
pv on contextual click Longint 15
pv on double clicked Longint 4
pv on drag Longint 10
pv on drop Longint 11
pv on getting focus Longint 0
pv on keyboard Longint 6
pv on losing focus Longint 1
pv on right clicked Longint 3
pv on row resize Longint 13
pv on scrolled Longint 5
pv on selection changed Longint 7

If no method has been linked to an event, PV Get on event method returns an empty string.

Example  

It is wise to temporarily disable an on event call and execute a process before re-establishing the original call.
Here is a simple method that generates this "disengagement" in a generic manner using PV Get on event method, for example, for the pv on cell value changed event:

 C_STRING(32;$EventMethod)
 
  `Save the method that may be in place
 $EventMethod:=PV Get on event method(Area;pv on cell value changed)
 
 PV ON EVENT(Area;pv on cell value changed;"") `Cancellation
 
  `... Put the process to execute here
 
 PV ON EVENT(Area;pv on cell value changed;$EventMethod`Restore

 
PROPERTIES 

Product: 4D View
Theme: PV Area
Number: 15993

 
HISTORY 

Created: 4D View 6.8

 
SEE ALSO 

PV Get on command method
PV Get on error method
PV ON EVENT

 
ARTICLE USAGE

4D View Language ( 4D View v11.4)
4D View Language ( 4D View v12)
4D View Language ( 4D v13)
4D View Language ( 4D View v14 R2)
4D View Language ( 4D View v14)
4D View Language ( 4D View v14 R3)
4D View Language ( 4D View v14 R4)