Trying to do something a bit funky. I want to display a custom control/form to allow the operator to select a proposal from those that are active on the constituent's record.
Imports IOMlibrarytestto the top of the file
o = CreateObject("IOMlibrarytest.Test")
Unfortunately I am struggling to get IOM to use the types and methods that the DLL contains. Instead, I get the following error:
Line 1: Error in custom code AfterConstituentOpen: Cannot create ActiveX component. Line:0 -->ImportOM.CImport.Process()
What have I missed?
Oh, by the way, I've made a minimal code sample as part of my testing. Might be handy to rule out my stupid coding.
Can't seem to attach a file here, so here's a link for download: http://tdwright.co.uk/IOMlibrarytest.zip
All it contains is two VS projects. One is a really lightweight class that just contains a public static string. The other is just a console application that reads the string from the class and prints it to screen.
The console application reads the string no problem, but IOM spews out the "Cannot create ActiveX component." error.
Plus, I've tried adding a ".init()" to the CreateObject call. No luck.
Any outside .NET application would need to be located in your plugins folder or registered in the GAC (Global Assembly Cache). Placing your dll file in the plugins folder is an easier solution.But, after using regasm I've found that I can get it to work. Annoyingly, I'm not sure which step I took was the critical one and it may not have been the registration. Next time I'll be more systematic. :(