Thursday, April 26, 2012

Composite Reporting With Mixed Orientation

I have spent the last two weeks researching different reporting tools for Delphi. I currently own Delphi 2010 Professional which comes with Rave built into the IDE. My customers have asked me for a "one-click" printing solution. Instead of previewing and printing each report one-at-a-time, they would like to simply press the [ Print ] buttton once and "presto" all the reports get printed. That is a fairly reasonable request.

Rave

So, I tried firing up the built in Rave tool. My first impression was tremendous anxiety. I literally felt like I was in the cockpit of an airplane staring at all these unrecognizable controls. The database product I use is ElevateDB and I had failed at several attempts to get hooked up to an active dataset. Finally, I somehow stumbled into a control that produced live data. I felt like on was on track.

So, now I'm looking to see how I can create a composite report. I like the idea of providing my customers with a "one-click" solution. However, the reports I need to create are a combination of portrait and landscape orientations. Now, the task has just gotten a little more trickier.

I need to create a composite report that allows a combination of portrait and landscape orientations.

I begin my quest for knowledge like I always do... StackOverflow. I quickly came across the following post regarding Rave. Migrating from QuickReport to FastReport, Rave Reports or what? This sounded interesting seeing how my older programs used Quick Reports. After reading some of the comments it further drove me away from Rave.

Quick Reports

I'm familiar with Quick Reports I even purchased the profession version when I was using Delphi 5 Enterprise. I know Quick Reports lets you create composite reports but does it allow for the mixing of portrait and lanscape orientations withing a single report. The answer is no. Here is the response I received from the developer:

Hi,

It can't be done with the present code. I'm not sure why but mixing report orientations just doesn't work.

Regards, QBS Software Ltd

So, Quick Reports is out. That's too bad because I have already spent several hours with that tool even though it was eight years ago.

FastReport

Now this looks promising. FastReport comes bundled with Delphi XE2 (which I will be upgrading to fairly soon). So far so good. I'm still waiting to here from them wether they support mixed orientation within a composit report. I'll update this post when I find out.

Report Builder (Digital Metaphors)

This is the reason I am writing. The answer is YES. Report Builder supports a composite report with mixed orientation. I sent three emails and received three emails from the sales and support team at Digital Metaphors within a 1 hour span. Not only did they answer my question, they gave me a link to Delphi code that shows an example of how to do this very thing. But wait there's more. . .

Here is their mission statement lifted right off the website...
At Digital Metaphors Corporation we believe that our existence is guaranteed only when we successfully complete the actions listed below on a daily basis:

  • Create software of the highest quality
  • Ensure that customers receive the maximum possible value from our software
  • Go the extra mile in every phase of the software business
  • Make things go right
  • Regardless of circumstances, use intelligence, common sense, and inspiration to create results which are a service to both our customers and our fellow employees
  • I started looking around their website for some nuggets and I came across a download called Learning ReportBuilder. This is a hands-on learning experience. It combines a 145 page step-by-step guide with a report builder tool that thoroughly teaches you how to use their product.

    I definitely felt like I was in the cockpit of an airplane looking at all the controls except this time, there was an instructor sitting right by my side guiding me through each maneuver. The controls will look familiar to any Delphi programmer. If you are in the market for a reporting tool, I urge you to download the Learning ReportBuilder hands-on tutorial before you make a decision. It's that good.

    I want to thank David Cornelius from cornelius concepts for telling me about Report Builder.

    Semper Fi,
    Gunny Mike

    5 comments:

    1. I can confirm. You can mix Portrait and Landscape Reports in Fastreport without problems. Just enter this piece of code for every report you want to print
      frxReport1.LoadFromFile('Portrait.fr3');
      frxReport1.PrepareReport;
      frxReport1.LoadFromFile('Landscape.fr3');
      frxReport1.PrepareReport(False);
      frxReport1.LoadFromFile('Portrait2.fr3');
      frxReport1.PrepareReport(False);
      frxReport1.Print;

      ReplyDelete
    2. We chose ReportBuilder as our standard reporting tool, and to provide users with the ability to write their own reports, many many years ago. And we have never regretted this decision. In my opinion, it is one of the most elegantly written and well designed Delphi component sets available.

      Not only is the reporting engine very very good (we moved away from the mighty Crystal to RB), the ability to get into the report in code while it is processing means you can do anything at run-time. You can inject extra criteria into the report's query (using the awesome SQLBuilder class), as well as extend the procedures and functions available WITHIN the report.

      We use it now to provide over 250 standard reports, a report editor, a report scheduler (any report, any time, to any destination with as many different parameters as you need), as well as using the Server product to make any selected reports visible in the browser.

      Plus, as this article alluded to, their technical support is first class.

      ReplyDelete
    3. Over the lifetime of your applications and reports you'll need more than one unorthodox thing. And believe me Fastreport supports a billion of those options. If you want an answer, the best place is to ask on the FastReports forums. I assume that's where you asked? It is a 1% requirement, and if it turns out you need that and Report Builder has it and fast reports doesn't at least you're choosing between two equally excellent packages. Rave is dead. Nevrona is dead. Don't put even one minute into Rave. Add it to the long list of dead delphi technologies, like the Blackfish SQL database, EDO, Delphi.NET, Kylix/QT/CLX, and many many more dead-end technologies.

      ReplyDelete
    4. I've chosen my fair share of dead-end component sets over the years, so thank goodness that ReportBuilder and FastReports seem to be going so strong! It does the two of them good to have the competition.

      ReplyDelete