Sub EventOnAfterAddSheet(Args: IUiPrxSheetEventArgs);
Begin
//set of operators;
End Sub EventOnAfterAddSheet;
Args. The parameter that enables the user to work with event parameters.
The EventOnAfterAddSheet method implements the event that occurs after adding a sheet.
To implement the event that occurs after deleting the sheet, use the IPrxReportUserEvents.EventOnAfterDeleteSheet method.
Executing the example requires a regular report. Connect a unit to the regular report, select the connected unit an the EventsClass class as an event handler. Add links to the Metabase, Report, Ui system assemblies in the unit.
Class EventsClass: ReportEvents
Public Sub OnAfterAddSheet(Sheet : IPrxSheet);
Begin
WinApplication.InformationBox("Sheet is added " + Sheet.Name);
End Sub OnAfterAddSheet;
Public Sub OnAfterDeleteSheet(Sheet : IPrxSheet);
Begin
WinApplication.InformationBox("Sheet is deleted " + Sheet.Name);
End Sub OnAfterDeleteSheet;
End Class EventsClass;
On adding and deleting the sheet in the regular report an information message is displayed.
See also: