save_document
Saves the active Inventor document without dialogs, writing changed dependents first while skipping library and Content Center files. Returns files saved and skipped, and validates the path before saving.
Instructions
Save the active document — never opens a dialog, and never writes a library or Content Center file. Dependents that changed (e.g. sub-assemblies, edited parts) are saved one by one first, except files in the project's library paths or Content Center folders and Content Center members: Inventor marks standard parts dirty after opening an old assembly, and re-saving them would rewrite shared library files. Returns the files saved and the ones skipped. The path is checked first (characters, extension, an existing file) so a bad one gets a clear message instead of Inventor's E_INVALIDARG.
Args: path: Full file path to save as (e.g. "D:/parts/flange.ipt"). If empty, saves in place. overwrite: Replace a file that already exists at path (not one open in Inventor). save_dependents: False = save only this document (Save2(False)); changed dependents stay unsaved and are listed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | ||
| instance | No | Which connected Inventor to use (list_instances). Leave empty when only one is connected. | |
| overwrite | No | ||
| save_dependents | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |