Solved

.PCH file missin fatal error 1083

Posted on 2002-05-06
5
833 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

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
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.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

760 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now