Hi Marco,

Templates in our case are simply HTML files that include "record"
delimiters and "field" markers. Records are simply blocks of HTML. Report
bands might be delimited by records for page header, column headings, rows,
page footings, etc.

I really like using HTML to create reports because it's so perfectly suited
for it and so well documented, although there may be a learning curve.
There are lots of WYSIWYG editors. A couple people in our shop use
Dreamweaver. Another prefers Visual Studio Code. My inclination is to let
users select the editor of their choice so long as the output is pure HTML.

Our reporting is facilitated by an RPG service program that exports a
handful of procedures that write IFS stream files based on templates.

RPG programs produce formatted output by writing records. If records
include field markers, a procedure may be called to output program data in
that space.

RPG programs that produce reports typically invoke the following procedures:

stmFmtLoad(name) - Loads a named template into program memory and returns a
reference to it.

stmFileOpen(path) - Creates or clears an IFS stream file which is
identified by a path name and prepares it to receive formatted output.

stmRecSet(name) - Positions template to a named record.

stmVarSet(name : value) - Replaces a field marker with the value of a
program variable.

stmRecWrt(name) - Outputs a block of HTML, which is identified by a record
name, to the IFS stream file.

stmToPDF() - Transforms the stream file to PDF format.

We've never run into any constraints (neither inputs nor formatted output)
under this approach and it's super reliable.


On Tue, Jul 20, 2021 at 1:12 AM Marco Facchinetti <
marco.facchinetti@xxxxxxxxx> wrote:

Hi Nathan

Essentially correct, at the moment the part that is supported and that does
not give particular problems is the insertion of references to the fields
(Xml) used as mail merge. But there is no support for FreeMarker syntax.
The generation part through the daemon is quite stable and reliable but, as
you pointed out, the format of the Office documents is complex and evolving
and xDocReport has not been updated anymore.

One thing that has worked well so far is that the dictionary of fields to
draw from is maintained by us and always aligned. This does not help with
the FreeMarker syntax which cannot be checked when editing templates.

I still hope to find a reliable product that meets our needs, alternatively
we will evaluate the possibility of collaborating with open-type projects
to which we can contribute the missing or non-working parts. The fact
remains that we are oriented towards the use of RPG and JavaScript so this
does not make us the best candidates for this type of solution.

Best regards
Marco Facchinetti

Mr S.r.l.

Tel. 035 962885
Cel. 393 9620498

Skype: facchinettimarco

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2021 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.