TECH TIP: Detecting Whether PrintDialog’sĀ Cancel Button Was Selected
When the print dialog is displayed to the user, you can determine whether the Cancel button was selected by using theĀ Report.OnPrintDialogClose event.
Example:
1 2 3 4 5 6 7 |
procedure TForm1.ppReport1PrintDialogClose(Sender: TObject); begin if ppReport1.PrintDialog.ModalResult = mrCancel then ShowMessage('Use chose to cancel the print request'); end; |