vc 常见错误代码

error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup

        reasons:控制台程序入门应该是main,错误的弄成了winmain;windows程序入口应该是winmian,错误的弄成了main。

        solution:1. Configuration Properties->Linker->System,然后在右边栏的SubSystem对应的项改为Windows(/SUBSYSTEM:WINDOWS)

                    2. Configuration Properties->C/C++->Preprocessor,然后在右边栏的Preprocessor Definitions对应的项中删除_CONSOLE, 添加_WINDOWS

error C2440: '=' : cannot convert from 'const char [11]' to 'LPCWSTR' 。除了这个还有2664 等一系列和LPCWSTR有关字符集的错误。

        solution:Configuration Properties->General->Character Set, change Unicode to Multi-byte.

fatal error LNK1120: 1 unresolved externals

        solution:  Configuration Properties->Linker->Input->Additional Dependencies, type the name of .lib file. ex: ddraw.lib.

没有找到msvcr90d.dll 错误

                      Configuration Properties -> Manifest Tool;在右边窗口中设置 Use FAT32 Work-around 项为 Yes.单击确定退出.

                      or:在“属性”->“C/C++”->“代码生成”->“运行时库”里面设为“多线程DLL”。

        





转载于:https://www.cnblogs.com/zzrnature/archive/2011/02/26/1965634.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值