rws Posted April 26, 2003 Posted April 26, 2003 Using VB in VStudio.NET Pro. The app needs to talk through the serial port (COM1). I have added Interop.MSCommlib as a reference (derived from mscomm32.ocx) and have written a class which inherits from MSComm. It works just fine on my XP machine, both in the development environment, and installed. For deployment, I have selected these properties for the mscomm32.ocx file on the target machine: selfReg, application folder, non-permanent. Install and uninstall both work, but the program won't run. I get: System.Runtime.InteropServices.COM Exception 80040112 I'm pretty sure it has to do with licensing ActiveX controls, a subject I know nothing about. The Help isn't helpful, since it seems to focus on licensing custom controls, not Microsoft controls. I know I should be using the mscomm32.ocx file registered on the target machine, rather than deploying another copy to the application folder, but I don't know how to do this, and I am especially worried about losing it during an uninstall. Has anyone else run into this problem? Any help would be appreciated. Thanks. Quote
*Gurus* Derek Stone Posted April 27, 2003 *Gurus* Posted April 27, 2003 There are plenty of .NET classes available online for accessing the serial port. I'd avoid COM problems and dump the MSComm32 control altogether. COM Exception 80040112 is a licensing problem, just to confirm that statement. Quote Posting Guidelines
rws Posted April 27, 2003 Author Posted April 27, 2003 Thanks, Derek. I am about ready to give up on MSComm32. I have found this alternative. Can you suggest any others? Also, thanks for confirming the error message. Quote
*Gurus* Derek Stone Posted April 27, 2003 *Gurus* Posted April 27, 2003 I'd use that code example. It's straight from Microsoft, which usually is a good thing. Others can be found on Google: http://www.google.com/search?hl=en&ie=UTF-8&oe=UTF-8&q=serial+OR+comm+port+vb.net Quote Posting Guidelines
Recommended Posts