Click to See Complete Forum and Search --> : unresolved external symbols


sakee
May 9th, 1999, 01:35 AM
I need to make use of a MFC function in a C program (windows environment) so i included
the header file (ie MFC.h) for the MFC function in the C file. when complied using Visual C++ 5.0 i have
unresolved externals symbols during linking. the unresolved external symbols belong to the
MFC function that i want to use. I have also tried to use extern but it doesnt help. And the MFC>h and MFC.cpp files have been added to the project space (using right click -> add files to project). Does
anyone has any idea? Thanks in advance.

Fraser
May 9th, 1999, 07:22 PM
Make sure that in Project / Settings, you have selected MFC from the "General" tab.

If you don't, then the appropriate libraries will not be linked, hence the unresolved externals.

Hope this helps.

sakee
May 9th, 1999, 09:24 PM
I have done that too ie set the project setting to "USE MFC as SHARED DLL"

sakee
May 9th, 1999, 09:37 PM
Also, the C program is already a DLL and the MFC code is a stand alone program.

Fraser
May 10th, 1999, 10:21 PM
Oh. Sorry. I don't have too much XP with DLL's.

Sometimes DevStudio is really annoying. Maybe a complete re-build will do the trick, if not then I don't know.

eric33
May 11th, 1999, 01:54 AM
What exactly is your problem ?
What is exactly the unresolved external symbol ?
What do you mean with "MFC.H" ?

Perhaps more precise informations could help finding a solution to your problem.