Hi Everyone,
I'm trying to develop a device plug-in , which will instantiate
the device specific dll and load in to the system.as example
I have barcode device and I wrote the wrapper class for the vendor specific
dll with the device specific configuration.Then in the device registering
program[part of my application] will read the those dll in specific folder
and then create the instances of each dll file in the given folder as given
below.
newDevice.Instance =
(IDevice)Activator.CreateInstance(DeviceAssembly.G etType(DeviceType.ToString
()));
Here IDevice is Interface that use for all device.
But following exception has thrown when trying to execute above line.
" Exception has been thrown by the target of an invocation."
When I check the message of inner exception of the above exception , it says
"Class is not licensed for use "
When I went further I found that exception actually thrown by the following
code line
MSCommLib.MSCommClass mPort=new MSCommLib.MSCommClass();
I did my best to figureout this.So if anyone tell me what should I do to
overcome this.
I'm using
MS Windows 2000 Server
..NET Framework 1.1
msomm32.ocx [ version 6.0.81.69]
Any Ideas ?
----------------------
Sumeda Herath