-
May 22nd, 2008, 02:22 AM
#1
Error 1 fatal error C1083: Cannot open precompiled header file: 'Debug\123.pch': No s
Hello to all expect MFC programmer, i use AppWizard to generate some classes for my application but return this kind of error where i cannot solve.
The project name is 123.
When i double click the error in error list, it show the error appear in
#include "stdafx.h"
What is the purpose and function of this header file ?
Thanks for your help.
-
May 22nd, 2008, 03:04 AM
#2
Re: Error 1 fatal error C1083: Cannot open precompiled header file: 'Debug\123.pch': No s
After few research, the answers is go to project properties and set it not using precompiled headers.
What is precompiled headers, purpose and function ?
-
May 22nd, 2008, 12:40 PM
#3
Re: Error 1 fatal error C1083: Cannot open precompiled header file: 'Debug\123.pch': No s
-
May 22nd, 2008, 01:25 PM
#4
Re: Error 1 fatal error C1083: Cannot open precompiled header file: 'Debug\123.pch': No s
For Visual C++ compiler a PCH is one which rarely changes. So, when you Rebuild; or Clean, Build, the contents of PCH (generally, stdafx.h ) is NOT compiled - thus saving compilation time.
Compilation time further reduces when you put all (or most) required headers into this header. This, way none of those included files will get compiled again (since compliler know that aren't changed).
Please note that if PCH file (stdafx.h) or any of the files included changes, the compiler WILL compile the file. Modifying stdafx.h may result in whole program compilation!
For short projects you may omit usage of PCH, but for moderate and large projects, you should use this feature.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|