Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

quickreport questions

Status
Not open for further replies.

room24

Programmer
Dec 28, 2003
83
JM
anyone here has any quickreport experience?? what version of quick report is packaged with delphi 6? where can i get some some sample code to look at for quickreport. Can anyone provide some sample code because i am trying to create a report using delphi 6 but it is just non coming up. i am trying to use the preview mode. i find the help that comes with delphi is not too helpful in solving my problems.
 
Not sure what code you need in particular but the following steps work for me.

1.
Select File->New->Other->Report->OK
2.
In the OI Name Property name it QuickReportmine. (Whatever)
3.
Drop a TDateSource (from DataAccess pallet) and a TTable (from BDE pallet) components
onto it. (If you are using a DataModule instead you need to include it in your Uses clause with F12.
4.
With the OI select your TTable with the the DataSet elipses in the DataSource.
5.
Click on the Form. With the OI DataSet Property elipses select your DataSet component.

6.
Click on the "+" in the Bands Property in the OI. Select the bands you need.
(Have at least a "Column Header" and a "Details" band.

7.
From the QReport pallet (D6) select the required QRDBText components to drop into the
Column Header. Set the DataSet and DateField Properties accordingly with the OI.

These will only print once on the top of the form.

You could also drop a TQRLabel near it to identify what the field represents. Especially
above the fields in the Detail Band.

8.
Select individual QRDBText components to drop into the Detail band,
Set the DataSet and DateField Properties accordingly with the OI.

These will repeat when the form prints.

9.
Save it to c:\MyFolder\QRMine.

10.
The event holder code you need to preview the form before printing. Recommended.
Code:
procedure TfrmGL.btnPrintClick(Sender: TObject);
begin
  QuickReport[b]mine[/b].Preview;
end;

Or you could go straight to a Printout with ...
Code:
procedure TfrmGL.btnPrintClick(Sender: TObject);
begin
  QuickReport[b]mine[/b].Print;
end;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top