1 ;在 VS2005 里写个最简单的语句 MessageBox("Hello,World!"); 出现错误提示: error C2664: ‘ CWnd::MessageBoxW ’: cannot convert parameter 1 from ‘ const char [13] ‘ to‘ LPCTSTR ’查找到解决方法是改成 MessageBox( _T ("Hello,World!")); 或 MessageBox(TEXT( “…”)) 因为 2005 中默认的是 unicode 的, char 是非 unicode 的。不同于以前在 中的写法 MessageBox("Hello,World!") 可以在 VS2005 项目属性中改变设置 General->Character Set->Not Set 2; C++ 问题: fatal error C1083: Cannot open include file: '': No such file or directory 悬赏分: 20- 解决时间: 2009-12-30 20:50 // #include <> double power (double x, int n); int main() { cout << "5 to the power 2 is" << power(5,2) << endl; // 函数调用作为一个表达式出现在输出语句中。} double power (double x, int n){ double val = ; while (n--) val *= x; return(val); } 运行时出现如下情况--------------------Configuration: 3_1 - Win32 Debug-------------------- Compiling... c:\c++\ 代码\example\ 例题源代码\ch03\(2) : fatal error C1083: Cannot open include file: '': No such file or directory 执行 时出错. -1 error(s), 0 warning(s) 求各路 C++ 大侠帮忙解决要具体一点嘿嘿问题补充: 已经将#include <> 改为#include <iostream> using namespace std; // 必须分两行明白了以下几点,问题就搞清楚了: 1 、要区分标准 C 的库和标准 C++ 的库。 iostream 是 C++ 的库, 是标准 C 的库。2、新的 C++ 形式的头文件, 所以在 vs200 5 里面是没有 的头文件的。3、在早期的 vs 版本, 比如 , 用的还是老版本的 C++ 标准库, 例如 , 并且当时标准库也没有引入名字空间。因此直接#include <> 是可以的。但到了 vs2005 ,使用了新的 C++ 标准库,只能用#inc
VS2005使用问题记录 来自淘豆网www.taodocs.com转载请标明出处.