EventOnBeforeChangeControlValue (Args: IUiPrxControlCancelEventArgs);
Args. The parameter, which enables the user to work with event parameters.
The EventOnBeforeChangeControlValue method implements the event that occurs before the value of a regular report control is changed.
The method enables to redefine the system event that occurs after the ReportEvents.OnBeforeChangeControlValue event.
Executing the example requires that the repository contains a regular report with connected unit. The connected module and the Parent class must be specified as event handler.
Add links to the Report, Ui system assemblies.
Public Class EventsClass: Parent
Public Sub OnBeforeChangeControlValue(Control: IPrxControl; Var Cancel: Boolean);
Begin
//Call system event redetermined in the Parent class
Inherited OnBeforeChangeControlValue(Control, Cancel);
End Sub OnBeforeChangeControlValue;
End Class EventsClass;
Class Parent: ReportEvents
// Handle the EventOnBeforeChangeControlValue event
Public Sub EventOnBeforeChangeControlValue(Args: IUiPrxControlCancelEventArgs);
Begin
WinApplication.InformationBox("Control value will be changed");
End Sub EventOnBeforeChangeControlValue;
End Class Parent;
After executing the example, before control value changes, the information message is displayed in regular report.
See. also: