Occurs after the import (or merge) operation has successfully completed.
Assembly: Microsoft.Office.Interop.InfoPath.SemiTrust (in Microsoft.Office.Interop.InfoPath.SemiTrust.dll)
This event handler does not allow users to cancel an operation.
If the merge operation includes merging multiple forms, the OnAfterImport event occurs only after all forms have been merged and the complete operation is successful.
There is no user interface (UI) in the InfoPath form design window for creating this event handler. To add this event handler to the project, include the InfoPathEventHandler attribute as it appears in the example.
If you create an event handler for the OnAfterImport event of a form template, you must edit the form definition file (.xsf) to set the useScriptHandler attribute of the importParameters element to "yes" before it will run.
In the following example, the OnAfterImport event handler is used to display a message box that informs the user that the merge operation completed successfully: