How to avoid a System.Runtime.InteropServices.COMException?

Your code (or some code called by you) is making a call to a COM method which is returning an unknown value. If you can find that then you’re half way there. You could try breaking when the exception is thrown. Go to Debug > Exceptions… and use the Find… option to locate System.Runtime.InteropServices.COMException. Tick the option to break when … Read more