Share
 
 

OnPostCloseDialog Function for Data Standard

For Inventor and AutoCAD, the OnPostCloseDialog function is called when clicking "OK" in a dialog, before the file name is set and the iProperties update.

This timing allows the code to still modify properties before the file is saved. This could be useful when users are not required to select a numbering scheme (see sample "Use Vault Numbering without showing the Number Scheme Control in the Dialog" for CAD in Example–Using Numbering Schemes in Data Standard.

In the default implementation the function doesn't do anything.

Usage

Called from the Inventor and AutoCAD Add-ins. The function is mandatory and cannot be removed.

A default implementation is available in:

  • C:\ProgramData\Autodesk\<Vault version>\Extensions\DataStandard\CAD\addins\Default.ps1

Additionally, the variable $dsWindow.Name contains the dialog name. By default that is either InventorWindow or AutoCADWindow.

These variables can be used to provide different implementations for different scenarios.

Was this information helpful?