Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Need main defined when linking ActiveX control?

Posted on 1998-09-22
1
Medium Priority
?
229 Views
Last Modified: 2010-08-05
I've written an ActiveX control (Visual C++ 5.0, Windows NT) and it compiles and links fine in the debug version. But when I try to link the release version the linker claims the symbol __main is undefined (reference from LIBC.lib(crt0.obj)). Any idea what is going on? I don't think I need to define a main procedure in an ActiveX control, do I?
0
Comment
Question by:webb
1 Comment
 
LVL 3

Accepted Solution

by:
xyu earned 800 total points
ID: 1173466
It's known problem if You link with libc.lib (e.g. You want to use static single threaded run-time) You can easily solve it by adding  "void main() {}" into any of Your cpp file. It never be called anyway... Or You can solve it by using other Run-time libs like Multithreaded DLL... but adding void main().. is most simple amd effcctive solution...
Good luck
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

This article will show you some of the more useful Standard Template Library (STL) algorithms through the use of working examples.  You will learn about how these algorithms fit into the STL architecture, how they work with STL containers, and why t…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
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.

927 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