3 Replies Latest reply: May 15, 2014 10:07 AM by Data Kruncher RSS

    Can one export a blank report

    drobert _

      First of all I want to know if it's possible to export to PDF a report that simply has headings but no data (detail and/or append).:confused:

       

      If it's possible, read on:

      Currently, I am able to detect that my original model/project does not have any detail, but I am not sure if I can, in the same model, simply output my Page Header and a special Page Footer line (indicating that there is no data), or would I need to create a special "blank" model to do this?

        • Can one export a blank report
          Data Kruncher

          As you've likely discovered, Monarch will gladly export a PDF file without any records displayed in the Table, but Adobe Reader won't open it.

           

          I suspect that you'll need a "blank" model and a related special "blank" report in order to create what appears to be a blank (headings only) PDF, but I haven't tried this myself so I'm not positive that it'll work.

           

          You need to force Monarch to create at least one record. Create a copy of your regular report and manually add another character outside of the normal text range. In your "blank copy" model, set your detail template to trap on that character and paint that field to capture it. All of the fields that normally appear in the report should still exist in the template.

           

          Now you should have a single record in the table, with nothing but blank values except your single character trap device. Hide that field, and export the PDF. It should have a record, albeit blank, so it [B]should[/B][/I] generate something for Adobe Reader to display.

           

          But reality may differ from my speculation. :confused:

           

          Try it out and post back. Any luck?

            • Can one export a blank report
              drobert _

              Yes, that was the solution!:D

               

              I was thinking about doing something similar, but more complicated... I was going to create a dummy record which contained all the pertinent information need for the detail trap, but that would prove to be prone to errors:( as anytime the report changes, the model will have to change and one may not think of also changing the batch file that inserts the dummy information.

               

              I simply inserted an additional line at the end of the report which was an "X" at the 150th column (which should never be in the data range) and created a detail trap to catch this and had no fields in this trap.  I created a Calculated Field which contained the phrase to indicate that it had no data (also some logic to change it according to the report's language) and used that it in my summary.  Bingo! It works!:D

               

              Thanks again, DK!