Macro to update all fields including header and footer

China☆狼群 提交于 2019-12-24 08:28:13

问题


I am using Word 2016 and have tried to use the Macro here: Macro to update all fields in a word document to update all the fields in my document (including headers and footers). However, now all the cross-referenced page numbers are set to "1", but everything else works perfectly.

But, when I select "Print" and just go back, all my fields and page numbers update correctly, including headers and footers.

Does someone know what "default" macro Word itself runs when you select "Print", but only the updating part?


回答1:


This could be an issue with your particular document. Incorrect page numbers might indicate that your document needs pagination. You can enforce pagination using this code:

ActiveDocument.Repaginate


来源:https://stackoverflow.com/questions/40928691/macro-to-update-all-fields-including-header-and-footer

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!