Solved

Compile error with VC++ 6.0

Posted on 2000-03-03
4
179 Views
Last Modified: 2010-04-10
When compiling my ocx I get:

error LNK2001: unresolved external symbol "long __cdecl APP_OpenAPP(long)" (?APP_OpenAPP@@YAJJ@Z)

My ocx is calling a dll that has function APP_OpenApp.

Any leads?

Didou

0
Comment
Question by:didou
4 Comments
 
LVL 2

Expert Comment

by:tdubroff
ID: 2581982
Looks like your linker is looking for the function from its local .obj files.  

I'm not sure at all about this, but I think, sometimes .lib's exist for certain .dll's that somehow tell the linker that the function is located in a .dll so it doesn't have to freak out about it.
0
 
LVL 32

Expert Comment

by:jhance
ID: 2582009
THIS IS A DUPLICATE QUESTION!

For some reason this guy keeps posting this question.  It looks like it's up to 4 posts now.
0
 

Author Comment

by:didou
ID: 2588321
I certainly did not meant to be abnoxiouz and send it so many time!
I don't know why it was posted
so many time!

How do I delete the question and
reclaim my points?

Thanks,
Didou
0
 

Accepted Solution

by:
werlwind earned 50 total points
ID: 2650720
It looks to me like a C++ name mangling issue.  Generally when calling DLL functions from withing C++ you want to make sure that the DLL function declaration in the header file is declared as extern "C", for example:

extern "C"
{
   long App_OpenApp(long);
}

Or something similar.  This will prevent C++ from modifying the function name internally as it normally does.

0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

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…
IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

832 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