Solved

MSComm32.ocx

Posted on 1998-03-18
5
228 Views
Last Modified: 2011-10-03
Hi,
I wrote a small program which uses the MSComm32.ocx to transfert data from serial port. On my computer, it works very weel, but when I want to execute it on a other computer, an error message tells me that a not supported operation was tempted. This error occurs each time that the program performs the UpdateData() function.  I used the class wizard to map a control variable to the ocx. My question is why it is working on my PC and not on other? I tried to compile my app whith the MFC in a static library but I got the same error.
Thanks
0
Comment
Question by:adnrwin
  • 2
  • 2
5 Comments
 
LVL 4

Expert Comment

by:jtwine100697
ID: 1183612
  Are you sure that the OCX is available and registered on the "other computer"?

-=- James.
0
 

Author Comment

by:adnrwin
ID: 1183613
The OCX wasn't registered on the other computer. I regitered it (with Visual C++ 4.0 CD) and my program worked. What files are needed to use the MSComm32.ocx and what my installation program does have to write in the registry for registering this OCX?
0
 
LVL 3

Accepted Solution

by:
stefanr earned 20 total points
ID: 1183614
You register OCX:es with the program REGSVR32.EXE, that is supplied with the NT system itself.

I.e.
C:\WINNT\SYSTEM32>regsvr32 mscomm32.ocx

To unregister, just use the /u switch. Theres no need to write in the registry yourself.

/Stefan
0
 
LVL 4

Expert Comment

by:jtwine100697
ID: 1183615
  "stefanr" is right...  You can make the calls to REGSVR32.EXE from your (un)install program.

-=- James.
0
 

Author Comment

by:adnrwin
ID: 1183616
Thanks guys!!
0

Featured Post

Active Directory Webinar

We all know we need to protect and secure our privileges, but where to start? Join Experts Exchange and ManageEngine on Tuesday, April 11, 2017 10:00 AM PDT to learn how to track and secure privileged users in Active Directory.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Fully specialized class template function 21 142
PDF library for Delphi 2 128
Excel/Word Add-in in what language? 5 128
Precision Problem in C++ 7 44
In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question