I am trying to use my first .NET control. (I have used ActiveX controls many times.) When I run my program I get the following error:
"There was a problem with one of the .NET support libraries. .NET assemblies cannot be loaded."
Here is the background:
I am using the 9.22 run-time and created my copy files with 9.22s NETDEFGEN.
My control comes in 2 .NET versions 3.5 and 4.0 I have tried both with the same result.
I have tried to install the control in the ACU dir with the wrun32 I am using and in a separate folder. (Uninstalling the control between installs.)
It is currently in a separate folder and I have created a netevents.ini with the path to the current install folder in my ACU folder.
My control does not show up in GAC but I browse to and everthing seems to go ok.
NETDEFGEN does not crate an events .dll that I can find but I don't think the control has any events.
I have tried the create statment with and without the event procedure.
My development machine is Windows 7 64 bit. The control is 32 bit. It comes in a 64 bit version but I believe I have to use the 32 bit for compatibility with Wrun32.
NETDEFGEN has created a copy file for the control and a NETObject.def copy file both of which I have under Special-Names in the Configuration Section.
I have the following in my working-storage:
77 CommSetting-HANDLE USAGE IS HANDLE.
I am using the following create statment:
NAMESPACE IS "PPPLink"
CLASS-NAME IS "CommSetting"
EVENT PROCEDURE IS EVENT-PROC
HANDLE IS CommSetting-HANDLE.
Here is the assembly from the copy book:
Here is the class from the copy file:
I have read through the .NET section of the interoperability guide and feel like I am doing what is required but am probably missing some thing.