com_refresh_fields
Update all document fields (TOC page numbers, cross-references) using an invisible Word instance to get correct page numbers after edits. Modifies file in place.
Instructions
Update every field in the document (TOC page numbers, PAGEREF, NUMPAGES, SEQ, cross-references) via an invisible Word instance, giving correct page numbers and computed values immediately. Use after insert_toc/insert_index/insert_caption_list for real page numbers, or after any edit that shifts pages. The source file is modified in place. Requires Word installed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||