G
ganziming
Unregistered / Unconfirmed
GUEST, unregistred user!
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, QRPrntr, StdCtrls;
type
TForm1 = class(TForm)
BtnOpen: TButton;
OpenDialog1: TOpenDialog;
QRPreview1: TQRPreview;
BtnPrnSetup: TButton;
procedure BtnOpenClick(Sender: TObject);
procedure BtnPrnSetupClick(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.BtnOpenClick(Sender: TObject);
begin
if OpenDialog1.Execute then
Qrpreview1.QRPrinter:= Tqrprinter.Create(self);
QRPreview1.QRPrinter.Load(OpenDialog1.FileName);
QRPreview1.PageNumber:=1;
Qrpreview1.PreviewImage.PageNumber:=1;
end;
procedure TForm1.BtnPrnSetupClick(Sender: TObject);
begin
if QRPreview1.QRPrinter <> nil then
QRPreview1.QRPrinter.PrintSetup;
end;
end.
D7 + QR 3.6
QRPreview1.QRPrinter.PrintSetup;运行没有反应。
???????
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, QRPrntr, StdCtrls;
type
TForm1 = class(TForm)
BtnOpen: TButton;
OpenDialog1: TOpenDialog;
QRPreview1: TQRPreview;
BtnPrnSetup: TButton;
procedure BtnOpenClick(Sender: TObject);
procedure BtnPrnSetupClick(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.BtnOpenClick(Sender: TObject);
begin
if OpenDialog1.Execute then
Qrpreview1.QRPrinter:= Tqrprinter.Create(self);
QRPreview1.QRPrinter.Load(OpenDialog1.FileName);
QRPreview1.PageNumber:=1;
Qrpreview1.PreviewImage.PageNumber:=1;
end;
procedure TForm1.BtnPrnSetupClick(Sender: TObject);
begin
if QRPreview1.QRPrinter <> nil then
QRPreview1.QRPrinter.PrintSetup;
end;
end.
D7 + QR 3.6
QRPreview1.QRPrinter.PrintSetup;运行没有反应。
???????