在编译VS时候,出现fatal error C1010: unexpected end of file while looking for precompiled head。

问题详细解释:致命错误C1010,在寻找预编译指示头文件时,文件未预期结束。就是没有找到预编译指示信息的头文件。

顾名思义就是预编译因为缺少了预编译文件而失败。解决方法显然可以取消预编译,或者帮助编译器找到预编译文件。

故解法:

1.右键单击项目工程中的cpp文件,在菜单Project->Settings->C/C++->Precompile Header,设置为第一项:Not using precompile headers。

2.在.cpp文件开头添加包含文件stdafx.h。 #include"stdafx.h"

已测试过OK

fatal error C1010: unexpected end of file while looking for precompiled header directive的更多相关文章

  1. fatal error C1010: unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source?

    解决方法:设置cpp文件的Precompiled Header属性设置为Not Using Precompiled Headers

  2. 解决错误 fatal error C1010: unexpected end of file while looking for precompiled head

    在编译VS时候,出现fatal error C1010: unexpected end of file while looking for precompiled head. 问题详解:致命错误C10 ...

  3. 【Visual Studio】解决错误 fatal error C1010: unexpected end of file while looking for precompiled head(转)

    原文转自 http://blog.csdn.net/liuqiyao_01/article/details/38867145 在编译VS时候,出现fatal error C1010: unexpect ...

  4. 关于” fatal error C1010: unexpected end of file while looking forprecompiled header directive”问题

    其中文意思是:致命错误C1010:意想不到的文件结束而寻找预编译头文件的指令错误执行cl exe. 经过多次的查找,终于解决这问题 方法一: 在头文件中加“#include "stdafx. ...

  5. C1010 unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source

    提示说是预编译出现问题,提示添加头文件stdafx.h,但是添加了也会继续有其他错误解决方法: 在菜单Project->Properties(或者直接快捷键Alt+F7)->C/C++-& ...

  6. 使用VC6.0编译C++代码的时候报错:fatal error C1071: unexpected end of file found in comment(Mark ZZ)

    fatal error C1071: unexpected end of file found in comment(Mark ZZ) 今天在一论坛上看到一人发帖: 『最近遇到一个奇怪的问题,代码中的 ...

  7. fatal error RC1004: unexpected end of file found处理方法

    资源编译器错误 RC1004 错误消息 遇到意外的文件结束 此错误是由于文本文件的最后一行中缺少换行符和回车符而造成的.

  8. fatal error C1071: unexpected end of file found in comment

    1.错误 #include<iostream> using namespace std; int main() { ..... return 0; } //如果把注释放到这里了,那么提交就 ...

  9. unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source 解决办法

    Project -> Properties -> C/C++ -> Precompiled Headers -> Precompiled Header -> 选择Not ...

随机推荐

  1. 深入分析JavaWeb Item43 -- Struts2开发入门

    一.Struts2概述 1.Struts2是什么? Struts2是一个M(模型-域–范围模型)V(View视图)C(控制器)框架(模型2).框架都是一个半成品. 提高开发效率. Struts1是一个 ...

  2. STM32学习之路之入门篇

    2006年ARM公司推出了基于ARMV7架构的cortex系列的标准体系结构,以满足各种技术得不同性能要求,包含了A,R,M三个分工明确的系列 其中A系列面向复杂的尖端应用程序,用于运行开放式的复杂操 ...

  3. Mybaits中的update

    <update id="update" parameterType="Currency"> UPDATE YZ_SECURITIES_CURRENC ...

  4. 《ASP.NET MVC4 WEB编程》学习笔记------乐观锁和悲观锁

    摘要:对数据库的并发访问一直是应用程序开发者需要面对的问题之一,一个好的解决方案不仅可以提供高的可靠性还能给应用程序的性能带来提升.下面我们来看一下Couchbase产品市场经理Don Pinto结合 ...

  5. SEH分析笔记(X64篇)

    SEH分析笔记(X64篇) v1.0.0 boxcounter 历史: v1.0.0, 2011-11-4:最初版本. [不介意转载,但请注明出处 www.boxcounter.com  附件里有本文 ...

  6. [SCOI2008] 着色方案[高维dp]

    321. [SCOI2008] 着色方案 ★★★   输入文件:color.in   输出文件:color.out   简单对比时间限制:1 s   内存限制:64 MB 题目背景: 有n个木块排成一 ...

  7. java中得到文件MIME类型的几种方法(转)

     本文转载自:http://hotsunshine.iteye.com/blog/857485 使用 javax.activation.MimetypesFileTypeMap 需要引入activat ...

  8. 阅读笔记:A Few useful things to Know About machine Learning

    这是Machine Learning领域的经典论文,文中提到了ML相关的12个keys,并自称这些keys是“black art”,我觉得有点像ML的“最佳实践”. 网上有此文的中文翻译,写得很详细, ...

  9. 修改bootstrap 的全局样式,bootstrap 3.0 是由html5和CSS 3组成的

    方法一: 不建议使用 * {}选择器,因为在一些其他样式插件.特殊部分会有更好的字体样式设定,用*就会全部覆盖. 正常引入bootstrap的css样式后,记得将自定义的样式表放到其之后, <l ...

  10. java个人所得税计算器

    class Caculate{ private String name; private double money; private double actual; /** * @param usern ...