Delphi 11.3 Host, VB.net plugin (visual studio 2022), Current version of Hydra.
When I unload the plugin, I get the OLE error 80131015. I’ve read the other 3 threads on this subject from 2013 and 2016. Is there any update information on how to counter this exception? The “AfterUnloadModule” event doesn’t fire in Delphi. Can I add something to the VB.Net plugin to trap the error? The assembly the plugin uses does connect to a network server.
The default application domain, which must remain loaded during the lifetime of the application.
An application domain with a running thread that cannot immediately stop execution.
An application domain that has already been unloaded.
Try to launch your plugin in debug mode in VS: use Delphi host as host application for your plugin or attach to Delphi host from VS.
When CannotUnloadAppDomainException is raised, you can get some info from exception’s properties.
as expected, event is fired after plugin is unloaded.
looks like you have open connection that cannot be terminated at once and it causes this issue.
try to terminate/close the connection to server and then unload your plugin.