[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Cwnd::KillTimer Compile problem.

Posted on 2006-04-30
10
Medium Priority
?
2,093 Views
Last Modified: 2008-01-09
Hi,

I'm trying to build the multiplayer project of the directshow MultiVMR9 sample.
This is probably dumb question but I'm stuck!  Using VS 2005 C++ Express.

The error:

Compiling manifest to resources...
Linking...
MultiPlayerDlg.obj : error LNK2019: unresolved external symbol "public: int __thiscall CWnd::KillTimer(unsigned int)" (?KillTimer@CWnd@@QAEHI@Z) referenced in function "public: void __thiscall CMultiPlayerDlg::OnDestroy(void)" (?OnDestroy@CMultiPlayerDlg@@QAEXXZ)
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argv
nafxcwd.lib(appcore.obj) : error LNK2001: unresolved external symbol ___argc
nafxcwd.lib(filelist.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(timecore.obj) : error LNK2001: unresolved external symbol __mbctype
nafxcwd.lib(apphelp.obj) : error LNK2001: unresolved external symbol __mbctype
Debug\MultiPlayer.exe : fatal error LNK1120: 4 unresolved externals

Any ideas please?  
0
Comment
Question by:ryanbe
  • 5
  • 5
10 Comments
 
LVL 8

Expert Comment

by:mrblue
ID: 16572393
0
 
LVL 8

Expert Comment

by:mrblue
ID: 16572425
OK, forget it (not the case)

Add to preprocessor definitions _AFXDLL symbol (I have found similar problem described couple times in Internet & as solution they suggested this).
0
 

Author Comment

by:ryanbe
ID: 16572445
you must have a better search engine then mine eh! :) Thought I had a pretty good hunt...
I added AFXDLL and that has reduced it to this:

Linking...
MultiPlayerDlg.obj : error LNK2019: unresolved external symbol "public: int __thiscall CWnd::KillTimer(unsigned int)" (?KillTimer@CWnd@@QAEHI@Z) referenced in function "public: void __thiscall CMultiPlayerDlg::OnDestroy(void)" (?OnDestroy@CMultiPlayerDlg@@QAEXXZ)
Debug\MultiPlayer.exe : fatal error LNK1120: 1 unresolved externals

grrrrr...
0
Independent Software Vendors: 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!

 
LVL 8

Expert Comment

by:mrblue
ID: 16572567
Just guessing

Aren't you just missing MFC library ?

Project->Project Setting and further "Use MFC in shared DLL" or "Use MFC in Static Library"

0
 

Author Comment

by:ryanbe
ID: 16572568
Any ideas please?  I'll try just about ANYthing, so have some fun with me.
0
 

Author Comment

by:ryanbe
ID: 16572658

I've added "Use MFC in Static Library" and "Static Link to ATL" because it does indeed need these. Have removed the _AFXDLL symbol.  Now have 36 errors starting with:

Linking...
LINK : warning LNK4199: /DELAYLOAD:OleAcc.dll ignored; no imports found from OleAcc.dll
MultiGraphSession.obj : error LNK2019: unresolved external symbol ___security_cookie referenced in function "public: virtual __thiscall CMultigraphSession::~CMultigraphSession(void)" (??1CMultigraphSession@@UAE@XZ)
MultiPlayer.obj : error LNK2001: unresolved external symbol ___security_cookie
MultiPlayerDlg.obj : error LNK2001: unresolved external symbol ___security_cookie

but! at bottom of list still the KillTimer error! dam.
elp! I owe you some points mrblue but will have to continue this tmrw, gotta z.
0
 
LVL 8

Expert Comment

by:mrblue
ID: 16572684
Bye the way have you changed project for "MultiVMR9 sample" ?
It should have correct settings & compile without problems.
0
 

Author Comment

by:ryanbe
ID: 16574913
Haven't changed the code. I got the "Server 2003 SP1" platform SDK and the samples included have no project files. I'm also using VS 2005 Express which is known to have several problems with older code. So I've had to convert the samples into new VS2005 solutions. Yes would be nice if I had VS2003 Enterprise and the samples came with project definitions and everything just compiled oh what a life it would be.

Maybe I'm going about it the hard way? Any suggestions much appreciated.
0
 
LVL 8

Accepted Solution

by:
mrblue earned 1500 total points
ID: 16576034
"which is known to have several problems with older code" - I am suprised and I don't have any super idea (by the the which update of DirectX SDK do you have - "Summer 2004" has both - MultiVRM9 & .SLN, .VCPROJ project).

Here comes settings for "MultiVMR9" project from older VS (.DSW, .DSP project) - good luck.

MultiVMR9:

 General tab:
  Not Using MFC

 C/C++ tab:
  General
    Preprocessor definitions:
      WIN32,_DEBUG,_MBCS,_USRDLL,MULTIVMR9_EXPORTS,_WIN32_WINNT=0x400,WINVER=0x400,_WIN32_DCOM,UNICODE,_UNICODE

 Link tab:
  General
   Object/library modules:
    ..\..\..\BaseClasses\Debug_Unicode\strmbasd.lib strmiids.lib ddraw.lib dxguid.lib version.lib odbc32.lib odbccp32.lib winmm.lib comctl32.lib d3d9.lib quartz.lib advapi32.lib ole32.lib oleaut32.lib user32.lib

MultiPlayer:
 General tab:
  Use MFC in Static Library

 C/C++ tab:
  General
    Preprocessor definitions:
      _DEBUG,WIN32,_WINDOWS,_MBCS,_WIN32_WINNT=0x400,UNICODE,_UNICODE

 Link tab:
  General
   Object/library modules:
    ..\..\..\BaseClasses\Debug_Unicode\strmbasd.lib strmiids.lib ddraw.lib dxguid.lib version.lib winmm.lib comctl32.lib quartz.lib d3dx9.lib  

GamePlayer:

 General tab:
  Use MFC in a Static Library

 C/C++ tab:
  General
    Preprocessor definitions:
      WIN32,NDEBUG,_WINDOWS,_MBCS

 Link tab:
  General
   Object/library modules:
    ..\..\..\BaseClasses\Release\strmbase.lib strmiids.lib ddraw.lib dxguid.lib version.lib winmm.lib comctl32.lib quartz.lib d3dx9.lib  


0
 

Author Comment

by:ryanbe
ID: 16576454

Sorry those settings no help. I have the October 2005 DX SDK which has no directshow samples.
I'm downloading the Summer 04 sdk and have HIGH hopes! :)
Thanks for your help. Sorry I am new to C++.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
Many modern programming languages support the concept of a property -- a class member that combines characteristics of both a data member and a method.  These are sometimes called "smart fields" because you can add logic that is applied automaticall…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.
Suggested Courses

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