I'd like to call John Z's script that writes pending metadata and refreshes data-driven categories from the Application script, imatch5.bas. I have two questions, the answers to which are probably obvious but which I can't figure out from the Help.
1. How should the file be structured? When the editor creates the script, it looks like this:
Sub Main
End Sub
Private Sub Application_Quit()
End Sub
To complete it, I want to call a modified version of John's script in Sub Application_Quit. Do I also need to call Application_Quit from Sub Main? If so, do I just insert Application_Quit() in Sub Main, like so:
Sub Main
Application_Quit()
End Sub
2. Is this the correct way to call another script from within a script?
Private Sub Application_Quit()
MacroRun (C:\ProgramData\photools.com\IMatch5\scripts\user\Writeback And Refresh (auto).bas)
End Sub
Thanks. Sorry about these obvious questions, but I'm not a script writer and I haven't been able to get this to work. I'm sure it's something very simple I'm doing wrong.
David