Show contents 

Report > Report Assembly Interfaces > IUiPrxSheetCancelEventArgs > IUiPrxSheetCancelEventArgs.Cancel

IUiPrxSheetCancelEventArgs.Cancel

Syntax

Cancel: Boolean;

Description

The Cancel property determines whether a particular action will be executed with a regular report sheet (calculation, saving).

Comments

If the property is set to True, the action is not executed; if the property is set to False, the action is executed.

Example

Consider the event that occurs before sheet calculation.

Sub EventOnBeforeRecalcSheet(Args: IUiPrxSheetCancelEventArgs);
Begin
    Args.Cancel := Not WinApplication.ConfirmationBox("Calculate " + Args.Sheet.Name + "?");
End Sub EventOnBeforeRecalcSheet;

When the event occurs, a dialog box to confirm calculation of the report sheet, containing the name of the sheet, is displayed. Answer Yes to calculate the sheet or No to cancel calculation.

See also:

IUiPrxSheetCancelEventArgs