I've inherited several hundred Word 2003 templates that are full of field codes. My users now have Word 2010. My data is in SQL-2005. I'm an experienced VBA & SQL programmer.
There are only about 25 fields in the 200 documents, so I'd like to get creating new documents from the templates to work as quickly as possible.
I have experience using Word templates with bookmarks, then running VBA to step through the bookmarks and paste data at each bookmark. But I haven't used merge with Word field codes for many years.
Any guidance from anyone who has done both about how to proceed?
1. Step through the template stopping at field codes and pasting data there (treat the field codes the same as bookmarks).
2. Convert all the templates replacing field codes with bookmarks, then using bookmarks as bookmarks.
3. Use VBA to do a Word merge setting the data source to be SQL with a where clause to only select the one row that should go into the document.
These are only going to be generated one at a time, on demand by users, the documents look to be mostly 1-3 pages long, so I don't think performance is going to be an issue. I would like to be able to reuse the documents in as close to the state they have been given to me as possible (jto get into production as quickly as possible), so I'm wondering if anyone has enough experience to offer guidance on the best way to go at this.