My first thought was also to do this in VB or VBA, but hey, this is the
Perlmonks Monastery not the
VB Nunnery (with my apologies to the members of the religious fairer sex).
If the existing templates are already set up to use the fields through some form of "mail merging" then all you have to do is have your Perl script spit out a "mail merge database file" and start MSWord through OLE and have it process the mail merge database file.
If mail merge is not an option, you're out-of-luck: you probably do not want to translate all existing template files into the MSWord HTML-format and then through some Templating system insert the right data at the appropriate places. As these templates are prone to be changed at any odd time, you will have to redo this exercise again and again.
CountZero
"If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.