Jump to content


Photo
- - - - -

Comprehensive Reporting Options Now Available Entirely Within ProIV


5 replies to this topic

#1 Ross Bevin

Ross Bevin

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 226 posts
  • Gender:Male
  • Location:Manzanillo, Colima, Mexico

Posted 30 April 2013 - 05:36 PM

Hi everyone,

Over the years we have often berated Northgate for ProIV's lack of reporting output capabilities. Now that they have made available Server Side Objects (SSO's) for PDF and Excel creation this is no longer the case. On Saturday we implemented a new document creation enhancement utilizing these two SSO's. I would like to share with you what we have done in case anyone out there wants to do something similar.

Prior to this enhancement our users could print a report to a printer or to Word. We also had a number of reports where the user could choose to output the report to Excel using Dynamic Data Exchange (DDE). We have special logic in the report function that handles this. DDE is clunky though in that the user cannot touch their screen while the Excel document is being produced otherwise output is disrupted, and it's also slow.

With our new enhancement a user can choose to output a report to a Printer, Word, PDF or Excel (for selected reports).

We have a global report function called WR_PRNS that is called in "Logic In" for all report functions. WR_PRNS set's @RPTOPT and it and the parent report function has spooling set to "Group Output" to keep everything together as one print job. Depending on the output selected by the user this function will do the following:

PRINTER - @RPTOPT is set to the selected printer share name. Based on the model of the printer, the report format and duplexing we write printer escape sequence codes to the beginning of the report to handle this.

WORD - @RPTOPT is set to output to a file named <@TERM>.doc. Based on the report format, we write a special format code string to the beginning of the report. This code is interpreted by a Word macro that will automatically format the report when opened. The format options are Standard, Elite, Compressed and Landscape Compressed. When the report is complete Word is invoked with the output file path.

PDF - @RPTOPT is set to output to a file named <@TERM>.rep. When the report is complete I read the output file and use the PDF SSO to write the lines to a PDF document. I use the spooler form ID code to determine how I created the PDF document e.g. Standard, Elite, Compressed and Landscape Compressed. I handle page breaks by checking the first character of the output file text line for a form feed. When the report is complete we invoke Adobe Acrobat Reader with the output file path. This was so simple to do that the code to do this only took a couple of hours to write and test. Yes, the text is still in courier but for standard reports this is a great way to turn them into PDF's.

EXCEL - I have created a global update function called WU_EXCEL that handles our Excel spreadsheet creation. If we want to give the user the option to send report details to Excel we simply call WU_EXCEL at various points in the report function. It gets called in "Logic In" first where we pass it the title, column headings and column formats. We call it again on the last field we print and pass it all the fields for the entire line in an array. We also call it where needed on control breaks. Finally it gets called again on "Logic Out" where we print an optional report legend and close the Excel document. Since we have standardized everything through WU_EXCEL it generally takes us less than an our to make a report Excel capable.

The main report function also calls another global report function called WR_PRNE in logical report 1 "exit logic". WR_PRNE performs various end of report duties depending on the output type. We print the optional report paramteters legend together with a line stating who printed the report and when. For reports sent to a printer we also include an escape sequence to reset the printer.

We also use the PDF SSO to create specialized documents such as invoices and PO's. The SSO is incredibly powerful and easy to use without the need to create style sheets and xml output. You simply build the PDF entirely through logic commands and paint the data, lines, boxes, images, tables, etc exactly where you want to place them on the page.

I have written this post primarily for those of you who are still on older versions of ProIV with very basic report generation capabilities. If you want to do what we have done you can now do so with the newer version of ProIV and by purchasing the PDF and Excel SSO's. You don't need to learn Crystal Reports, XSL Style Sheet creation or XML. All you need to learn are the SSO methods via ProIV logic commands.

Regards
Ross Bevin

#2 Matthews Estrice

Matthews Estrice

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 241 posts
  • Gender:Male
  • Location:Henley-on-klip

Posted 01 May 2013 - 11:56 AM

Hi Ross,

It seems like there is a great improvement on PROIV reporting side,someone is working hard out there to make PROIV a viable programming environment :p/> .I am excited to hear that we can now print pre-printed stationery (legal form),reports with control breaks and various types of reporting within PROIV environment.I will say :thum:/> for the team over there.

Are the documentations for all the SSOs available as per my attachment form ie. UML form?

We need every UI/API javadocs and UML(Unified Modelling Language) documentation for bidding/tenderring events for the prospects.The prospects always ask for API/UI documenations when requesting for quotation prices.The purpose for that is to minimise hacking and virus infections.

We use the attached documentation type for forensics and application protection.

Thank you for the update,

Matthews Estrice

ProInvest Software

Attached Thumbnails

  • UML_EventBilling.png


#3 Ross Bevin

Ross Bevin

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 226 posts
  • Gender:Male
  • Location:Manzanillo, Colima, Mexico

Posted 01 May 2013 - 12:39 PM

Hi Matthews,

The only documentation I have for the SSO methods is supplied in html format and is available with the install. It's pretty basic but if you follow the SSO demo functions you can quickly get up to speed on how to use them.

Regards

Ross

#4 Ross Bevin

Ross Bevin

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 226 posts
  • Gender:Male
  • Location:Manzanillo, Colima, Mexico

Posted 01 May 2013 - 12:47 PM

Here are some examples of the Excel and PDF report documents. I have changed the company name on the spreadsheet to protect my clients data.

Regards

Ross

Attached Files



#5 Matthews Estrice

Matthews Estrice

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 241 posts
  • Gender:Male
  • Location:Henley-on-klip

Posted 01 May 2013 - 01:10 PM

Hi Ross,

Thank you for the information.I still think that NGA can produce the UML docs linked to javadocs fairly easily off their IDE.

Is @TERM on the report name used so that no user can override other user's reports and for session (COMM) purpose,is that correct?


Matthews Estrice

#6 Ross Bevin

Ross Bevin

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 226 posts
  • Gender:Male
  • Location:Manzanillo, Colima, Mexico

Posted 01 May 2013 - 01:24 PM

Hi Matthews,

Yes, I use @TERM to name the output files so that they are unique per session. Once processed I actually rename them to a more meaningful name. I do this because we also give the user the option to archive reports. They can also lookup all the reports they printed during the day and re-open if required.

Regards

Ross



Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users