The problem seems to be "Application.UserName" which when changed to just "UserName" allows the macro to run, but then the field is empty in the header, so I took out the whole block for the header. I read elsewhere that "Author" may work. The header wasn't appearing on the first page, so that was another reason to cut the header contents. And the table's cell lines disappeared with the Word update, and I fixed that by adding .Borders.Enable = True to the block that formats the table.
The problem with the table lines is probably a 16.9.1 issue, because saving as PDF a document with a table seems to screw up the lines, across the board on most files. I've reverted to the pre-16 version of Word.
Last edited by JML; 02-04-2018 at 11:08 AM.
|