none
Word Template Automation Question RRS feed

  • Question

  • Hello,

    I have virtually no experience with developing anything involving Microsoft Office Word.  However, our team keeps running into problems which I think could be easily solved if we found a way to automate Word Document Creation.

    Basically, the problem is we daily generate word document reports that are formatted as similar to each other as possible and we currently do this manually.  I am hoping that there might be a way where we have text fields or something and once we input our data into those text fields and click run our program will take that user supplied data and automatically ensure the formatting is correct and will generate a Word Document report.  When we do this manually we spend way too much time adjusting line space, changing image sizes, configuring dates into a certain format, etc.  Does anyone have any ideas, suggestions, or advise on how to make this process more efficient?

    Thanks in advance,

    Joe

    Thursday, June 21, 2018 4:18 PM

All replies

  • If you create a Word template with the appropriate boilerplate text, all correctly formatted via the appropriate use of Styles, that will take care of most of your issues. Your users will, of course, need to use those Styles correctly, too, for any post-population editing they might be required to do. As for populating the document, you could use bookmarks, content controls and/or, where appropriate, tables, to indicate where the data should go. But, if the data are coming directly from a database, a mailmerge might be a better solution. A table cell with a fixed row height and column width, for example, can be used to constrain an inserted image's size to particular dimensions without the need for manual resizing. Unless you're using a mailmerge, Word won't reformat dates for you, though, so you'll need to modify your insertion process to insert them with the required format.

    Cheers
    Paul Edstein
    [MS MVP - Word]

    Thursday, June 21, 2018 11:14 PM