Unexpected end of file while looking for precompiler header file, when instrument my code through squish coco

180 Views Asked by At

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

I have already added #include "stdafx.h" file in my .cpp file

#include "stdafx.h"

msmq()
{

   int a;

    enter code here

}

But when I used Squish coco for code instrumentation at that time they ignore this precompiler file and give me error.

I expect it to instrument my code successfully without giving C1010 error.

I already tried Precompiler Disable option, but it didn't work successfully

1

There are 1 best solutions below

0
Mr.Bhavadip Gothadiya On

Yes, because of some space error in the header file.

Ensure that between #include and "Header file name" there is only one space.

#include "stdAfx.h" (2 spaces between #include and header file name)

If you give only one space instead of more then one then simply solve it:

#include "stdAfx.h" (only one space) it's work correctly..