I have some code where I use a .dll created with vb.net inside VS2013 to use with matlab:
net = NET.addAssembly('SOME_PROJECT.dll');AssemblyType = net.AssemblyHandle.GetType('SOME_PROJECT.ComClass');try result = System.Activator.CreateInstance(AssemblyType);catch e e.message; if(isa(e, 'NET.NetException')) eObj = e.ExceptionObject endend
This works fine in matlab 2017b and will yield 'result' but in 2018a I get a SEHException
e = NetException with properties: ExceptionObject: [1×1 System.Runtime.InteropServices.SEHException] identifier: 'MATLAB:NET:CLRException:AddSuperClasses' message: 'Message: External component has thrown an exception.↵Source: dotnetcli↵HelpLink: ' cause: {} stack: [0×1 struct]
What changes between 2017b and 2018a could cause this? What can I do to fix this?
Best Answer