Home > Back-end >  Xe5 frxReport1. DesignReport (); After no response, look at the others also have asked, consult!
Xe5 frxReport1. DesignReport (); After no response, look at the others also have asked, consult!

Time:09-26

In xe5 frxReport1. DesignReport (); Without any response, baidu found also asked the same question, especially, how to pop up the design interface

CodePudding user response:

Use TGRDesigner to design reports

CodePudding user response:

Design the report form code
The unit uReportDesigner;

Interface

USES the
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, OleCtrls grdesLib_TLB, OleServer grproLib_TLB;

Type
TfrmReportDesigner=class (TForm)
GRDesigner1: TGRDesigner;
GridppReport1: TGridppReport;
Procedure FormShow (Sender: TObject);
Procedure FormCreate (Sender: TObject);
Procedure GRDesigner1SaveReport (Sender: TObject);
Procedure GRDesigner1OpenReport (Sender: TObject);
Private
{Private declarations}
Public
{Public declarations}
StrReportFile: string;
end;

Var
FrmReportDesigner: TfrmReportDesigner;

Implementation

{$R *. DFM}

Procedure TfrmReportDesigner. FormShow (Sender: TObject);
The begin
GridppReport1. LoadFromFile (strReportFile);
GRDesigner1. Reload;
GRDesigner1. DefaultAction:=true;
end;

Procedure TfrmReportDesigner. FormCreate (Sender: TObject);
The begin
GRDesigner1. DefaultInterface. Report:=GridppReport1 DefaultInterface;
end;

Procedure TfrmReportDesigner. GRDesigner1SaveReport (Sender: TObject);
The begin
GRDesigner1. Post ();
GridppReport1. SaveToFile (self. StrReportFile);
GRDesigner1. DefaultAction:=false;
end;

Procedure TfrmReportDesigner. GRDesigner1OpenReport (Sender: TObject);
The begin
GRDesigner1. DefaultAction:=false;
end;

End.



Call the design report form code

 
If frmReportDesigner=nil then
The begin
FrmReportDesigner:=TfrmReportDesigner. Create (self);
end;
FrmReportDesigner. StrReportFile:=self. StrReportFile;
FrmReportDesigner. ShowModal;
Freeandnil (frmReportDesigner);

CodePudding user response:

Design the report form code

 
The unit uReportDesigner;

Interface

USES the
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, OleCtrls grdesLib_TLB, OleServer grproLib_TLB;

Type
TfrmReportDesigner=class (TForm)
GRDesigner1: TGRDesigner;
GridppReport1: TGridppReport;
Procedure FormShow (Sender: TObject);
Procedure FormCreate (Sender: TObject);
Procedure GRDesigner1SaveReport (Sender: TObject);
Procedure GRDesigner1OpenReport (Sender: TObject);
Private
{Private declarations}
Public
{Public declarations}
StrReportFile: string;
end;

Var
FrmReportDesigner: TfrmReportDesigner;

Implementation

{$R *. DFM}

Procedure TfrmReportDesigner. FormShow (Sender: TObject);
The begin
GridppReport1. LoadFromFile (strReportFile);
GRDesigner1. Reload;
GRDesigner1. DefaultAction:=true;
end;

Procedure TfrmReportDesigner. FormCreate (Sender: TObject);
The begin
GRDesigner1. DefaultInterface. Report:=GridppReport1 DefaultInterface;
end;

Procedure TfrmReportDesigner. GRDesigner1SaveReport (Sender: TObject);
The begin
GRDesigner1. Post ();
GridppReport1. SaveToFile (self. StrReportFile);
//GridppReport1. SaveToFile (' d: \ 2. GRF);
GRDesigner1. DefaultAction:=false;
end;

Procedure TfrmReportDesigner. GRDesigner1OpenReport (Sender: TObject);
The begin
GRDesigner1. DefaultAction:=false;
end;

End.

CodePudding user response:

reference 1st floor seleron response:
use TGRDesigner to design Report
this is Grid++ Report?

CodePudding user response:

Zbdenghu
reference 4 floor response:
Quote: refer to 1st floor seleron response:

Use TGRDesigner to design Report
this is Grid++ Report?


Mistake, mistake fastreport look into grid++

CodePudding user response:

Fastreport design report
FrxReport1. DesignReport;
There is no problem in the xe2,
Xe5 unused

CodePudding user response:

FrxReport1. DesignReport (); After
FrxReport1. ShowModal;

CodePudding user response:

refer to 7th floor u012072926 response:
frxReport1. DesignReport (); After
FrxReport1. ShowModal;
wrong

CodePudding user response:

Window is not TFxDesigner components,

CodePudding user response:

XE series own FastReport is FR to EMB custom, belong to the Lite version, full version only has DesignReport functions,

CodePudding user response:

Also met this problem, please answernullnullnullnullnullnullnull