Quinn-Curtis Forums
Quinn-Curtis Forums
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Tools for Windows
 Charting and Real-Time Graphics Tools for Windows
 LNK2005 Error in MFC 2008 Update
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Kyle.IBT

5 Posts

Posted - 14 Feb 2008 :  11:13:57  Show Profile  Reply with Quote
Hi-
I'm building an application w/ the new MFC Feature Pack for Visual C++ 2008 and keep running into tricky linker errors. I've rebuilt the QC MFC libraries in the QCW source folder but this does not seem to fix my problems. The first is a LNK2005 error for which I followed the steps from Microsoft (http://support.microsoft.com/kb/148652) which involved excluding two common libraries. But then i was confronted with another error when i invoked anything from the CTS32DD.lib.

"error LNK2001: unresolved external symbol "public: static struct CRuntimeClass const CObject::classCObject" (?classCObject@CObject@@2UCRuntimeClass@@B)" in CTS32DD.lib line 1

Which i take to mean that the CTS32DD.lib is not able to view the some MFC components. So i think that the problem still lies in the LNK2005 error regarding having CRT library and MFC libraries linked in the wrong order.

You can see my project here:

https://jshare.johnshopkins.edu/kfritz1/kf_web/kfGrpRibShrMFC.zip

The only QC things I do are to call WGStart() in Line 43 of kfGrpTibSheMFC.cpp and at line 43 of kfGrpTibSheMFCDoc.cpp , create an empty QCStaticData.

How can I solve my linker problems?

Thanks
Kyle


Kyle Fritz
Infinite Biomedical Technologies

quinncurtis

1164 Posts

Posted - 14 Feb 2008 :  11:24:57  Show Profile  Reply with Quote
The first thing we must say is that we do not recommend that anyone continue to push the old BMC-100, 200, GCL software forward into newer and newer versions of VS. We stopped all work on the software in early 2000, when there was only VS 6. We only continue to sell the product because we will have customers that use that compiler. We have tested the software with newer versions of MFC and have always been suprised when it remains compatible with newer versions.

That said, we will look at your project. But if there is some fundemental incompatibility with some MFC Feature Pack, we aren't going to be making any updates to the software.
Go to Top of Page

quinncurtis

1164 Posts

Posted - 14 Feb 2008 :  15:00:00  Show Profile  Reply with Quote
I don't think we are going to be much help on this.

Are you referring to the BETA MFC Feature Pack for VS 2008. We downloaded it from Microsoft, but we could not even get it to install, even though we have VS 2008, it couldn't find it. This is apparently a common problem with the feature pack.

I'm afraid that when it comes to Microsoft Beta software you are going to have to be on your own.

Here are a few things we would try.

1. The GCL library that you reference (CTS32DD.lib) is different from your previous project, the one that did not include the Feature Pack stuff and we could compile and run. Are you absolutley sure that you checked off all of the Project Configurations under Batch Build and did a Rebuild All? Check the dates of all of the *.lib files in the QCW32\MFCLib folder. They should all be current, separated by a minute or two.

2. Try and link in CTS32D.lib instead (that is the release version of the same library)

3. Change your project settings to use the shared version of MFC, and link in our CT32D.lib (or CT32DD.lib) libraries instead of the static versions you linked in.

We will continue to think about it and post if we have any suggestions.
Go to Top of Page

quinncurtis

1164 Posts

Posted - 14 Feb 2008 :  17:10:11  Show Profile  Reply with Quote
We were able to get he MFC Feature Pack Beta installed.

If we created a new MFC App that used some of those features (Office 2007 themed), and selected to use the shared version of MFC, we were able to add our our CT32DD.lib library, and related files, to the resulting project, and the WGStart method call, and compile and run it. If you start with a new project, you should be able to reproduce this in a few minutes.

However, if we used a project that linked in MFC statically, we could not get it to compile. We don't know the reason. If anything else surfaces we will post to this thread.

Go to Top of Page

Kyle.IBT

5 Posts

Posted - 14 Feb 2008 :  23:28:21  Show Profile  Reply with Quote
I also was able to call WGStart and compile the project. The linker error started when I tried to use a QCStaticData object. I will investigate tomorrow if the error is unique to QCStaticData class or it is so across the library.


Kyle

Kyle Fritz
Infinite Biomedical Technologies
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Quinn-Curtis Forums © 2000-07 Quinn-Curtis, Inc. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.07