I am new to using VC++
Now my problem is this.
I have a driver code . Developed as win32console application with c files and headers.
I also have a Videonet code (a dialog based application) . This has .cpp files.

Now i have to patch pieces of the driver application into the Videonet(dialog based win32 MFC application). The videonet workd fine by itself as also the driver code.

Now when i include the first header file(.h) from the driver application into the dialog based application, i get this error.

C1852: Debug/VideoNet.pch is not a valid precompiled header file

Actually my idea is to include the .h files of the driver under the header files of the VideoNet application and then add codes from the driver cpp files into the VideoNet application. Now how do i proceed. From the MSDN help , i found that this sometimes happens because of mixing .c and .cpp files
. So what could be done to go ahead For ur information there are these statements in the Videonet application that may be of interest.(may be conflicting)
#pragma comment(lib,"vfw32");
#pragma comment(lib,"winmm")

and also #ifdef __cplusplus
and so on
Please suggest what to do next.

Re: Visual C++ Language error : not a valid precompiled header file


I'd say that one of your source files is configured to use VideoNet.pch as a precompiled header, and that such as file is never created. Open your project properties, go to the configuration properties -> c/c++ -> precompiled header section and try disabling that.