procedure TRMPreview.btnPrintClick(Sender: TObject); begin if (Report = nil) or (not btnPrint.Visible) then Exit; //利用报表对象的tag来记录是否打印以及打印的次数 if (FReport.Tag = 0) or (MessageBox(Handle, PChar(‘当前报表已经打印过‘ + IntToStr(FReport.Tag) + ‘次了,确定再打印吗?‘), ‘提示‘, MB_OKCANCEL or MB_ICONQUESTION or MB_DEFBUTTON2) = mrOk) then Print; end;
时间: 2024-10-09 15:30:11