如何用VS.NET写MFC程序
我VS.NET试写了一段MFC程序,报告有链接错误:
MFCHello error LNK2019: unresolved external symbol __endthreadex referenced in function "void __stdcall AfxEndThread(unsigned int,int)" (?AfxEndThread@@YGXIH@Z)
MFCHello error LNK2019: unresolved external symbol __beginthreadex referenced in function "public: int __thiscall CWinThread::CreateThread(unsigned long,unsigned int,struct _SECURITY_ATTRIBUTES *)" (?CreateThread@CWinThread@@QAEHKIPAU_SECURITY_ATTRIBUTES@@@Z)
MFCHello fatal error LNK1120: 2 unresolved externals
我猜想是没加上某个DLL,但在Project菜单下,找不到Preject Settings,不知给挪到哪去了,那位明白人给指点一下。
问题点数:100、回复次数:9Top
1 楼FengYuanMSFT((6.4 被封杀)袁峰 http://fengyuancom.spaces.live.com)回复于 2004-05-02 06:01:44 得分 50
View -> Solution Explorer -> select your project -> right mouse clip -> PropertiesTop
2 楼zhaopeng3(菜鸟)回复于 2004-05-02 11:36:48 得分 10
使用多线程的运行库Top
3 楼dunai2003(马尔罗尼)回复于 2004-05-04 09:48:03 得分 0
怎样使用多线程的运行库?请楼上赐教。Top
4 楼endicking(Iori)回复于 2004-05-04 11:33:11 得分 10
#include"afxmt.h"
Top
5 楼dunai2003(马尔罗尼)回复于 2004-05-07 15:43:32 得分 0
自己顶一下Top
6 楼kpld8888(kpld)回复于 2004-05-07 16:01:37 得分 10
加入这个链接库:libcmtd.libTop
7 楼shootingstars(有容乃大,无欲则刚)回复于 2004-05-07 16:05:27 得分 10
回复人: FengYuanMSFT(袁峰)
View -> Solution Explorer -> select your project -> right mouse clip -> Properties
-----------------------------------------
呵呵,袁大侠不是说了吗?
接着在属性对话框中:C/C++ -> 代码生成 -> 运行时库选择多线程支持。(我是用的VS.Net中文版)
Top
8 楼dunai2003(马尔罗尼)回复于 2004-05-07 17:48:02 得分 0
谢谢上面几位指教。Top
9 楼PiggyXP(【小猪】技术太差没脸上班,只好去念Ph.D了-_-b)回复于 2004-05-07 20:17:43 得分 10
来晚了,楼主已经搞定了是吧-_-bTop




