Hi @jzietsman. Unfortunately, it is not going to be that simple. What you are trying to achieve, event though it may seem simple, would actually require some fairly advanced code to make happen. The type of code that would normally be put into an Inventor add-in, rather than an iLogic rule. Working with real event handler codes can be rather complicated, and can cause problems, if not handled correctly and efficiently. If we were able to make this happen using iLogic rules (multiple may be required), then at least one of those rules would need to be an external rule, because we are dealing with Inventor application level functionality here. And one rule may simply be to launch that other external rule's process, when the first new drawing document is created. The FileUIEvents object itself is obtained directly from the Inventor Application object, not from a Document. And the FileUIEvents.OnFileSaveAsDialog and FileUIEvents.OnPopulateFileMetadata events can be triggered with any document(s) involved.
I am not that familiar with the OnPopulateFileMetadata event yet myself, but after reviewing the OnFileSaveAsDialog Event properties and functionality, I'm starting to wander which may be better to use for this situation. It seems like both events get triggered when I click on the regular Save button to save a 'New' drawing that has not been saved yet. It is difficult to tell which event is really first (before the other), but at the moment it seems like the OnFileSaveAsDialog event may get triggered very slightly before the OnPopulateFileMetadata event does (I could be wrong though). When the OnFileSaveAsDialog event is triggered, the 'FileName' property of the event is empty, but the value of its 'TopLevelDocument' (in the Context) contains the 'DisplayName' of the document (without any file extension yet), and the 'InitialDirectory' (in the Context) contains a file path that seemed to not have anything to do with that document (somewhere that we may have saved some other file previously). When the OnPopulateFileMetadata event is triggered, within the 'FileMetadataObjects' is a FileMetadata object with the DisplayName (but this time with the default file extension included for that type of Document), but no file path, and no formulae, and in the 'Context' is a property named 'CommandName' with the value 'AppFileSaveAsCmd'.
Interesting stuff. But if I were to figure this out, I would need to do more research, and trial & error testing (when I find the time, while keeping up with other work/tasks). Maybe @TONELLAL could offer more insight about that one event, since he has used it before, but I am not sure.
Wesley Crihfield

(Not an Autodesk Employee)