Solved

.PCH file missin fatal error 1083

Posted on 2002-05-06
5
837 Views
Last Modified: 2013-11-20
i have used appwizard for MFC , here i have chosen DIALOG BASED appln. On compiling it results in a fatal error 1083 .PCH file missing. what is the reason for this error.IN one of my project directories the stdafx.obj file was missing.so i included it in the directory and complied the stdafx.h file after which the project that was reporting the .pch file was missing started working correctly..same steps upon following in another project still results ..it states the now the header file(stdafx.h) file requires a different tool to compile it.please guide...for the above 2 situation
0
Comment
Question by:kar11
5 Comments
 
LVL 12

Accepted Solution

by:
migel earned 25 total points
ID: 6993184
Hi!
check your projects Precompiled Header options in the C++ page
set it to the last option "Use precompiled header file *.pch"  and enter in the edit
stdafx.h
0
 
LVL 2

Assisted Solution

by:kozmo_jonny
kozmo_jonny earned 25 total points
ID: 6993275
in the CPP file of that same DIALOG

u need to include by that order :

1) stdafx.h
2) yourprojectname.h
3) yourdialogname.h

4) any other includes u might need for this dialog

enjoy

p.s.
did u try "Rebuild All" ??? this helps usually...

bye
0
 
LVL 16

Expert Comment

by:AlexNek
ID: 6993987
2 kar11
Important that the first line in each Cpp is:
#include "StdAfx.h"

Use compiler setting C++/Precompiler Header/Use precompiled header file (.pch) through header stdafx.h for full project and C++/Precompiler Header/Create precompiled header file (.pch) through header stdafx.h ONLY for the file stdafx.cpp
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone 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

Suggested Solutions

Title # Comments Views Activity
Is it possible to combine several text files into one big one? (redhat v5 enterprise) 4 110
Define unique primary key 9 95
twoTwo  challenge 35 113
unix example issues 18 106
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
In this post we will learn different types of Android Layout and some basics of an Android App.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

733 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