例如拖一个TPrintDialog控件出来,拖一个button1出来// button1 点击 procedure tform1.button1click(sender:tobject); begin if printdialog1.execute then begin // .... end; end;
我直接可以这样写吗? procedure TActiveFormX4.showPrintDialog(x: Integer); begin PrintDialog1.Execute; end; PrintDialog1 提示这个没定义。实在是太菜了,但是工作中需要用到,
都是显示一个打印相关的对话框,用它们的 execute 函数调用PrintDialog1.Execute;
PrinterSetupDialog1.Execute;
procedure tform1.button1click(sender:tobject);
begin
if printdialog1.execute then
begin
// ....
end;
end;
procedure TActiveFormX4.showPrintDialog(x: Integer);
begin
PrintDialog1.Execute;
end;
PrintDialog1 提示这个没定义。实在是太菜了,但是工作中需要用到,
然后
procedure TActiveFormX4.showPrintDialog(x: Integer);
begin
PrintDialog1.Execute;
end;