{{ !articles[0].partner.isSponsoringArticle ? "Platinum" : "Portal" }} Partner
dotnet,how-to,tools,windows,c++,visual studio,.net & windows,error,cx

C++/CX : How to Fix the “Precompiled Header File is From a Previous Version of the Compiler” Error

This is just a quick post about this error I sometime have when I change the targeted platform of my C++/Cx project: “precompiled header file is from a previous version of the compiler, or the precompiled header is C++ and you are using it from C (or vice versa)“.
When I read this the first time, I didn’t have a clue of what the error could be. In fact…

.. I think this is a Visual Studio issue and you only have to clean the project once to make everything works on the next build.

Some will maybe think it’s not worth a blog post but I tried a lot of things (and wasted a lost of time – including not watching the last walking dead !!!) before to find out it was this easy. I hope this post will save you this time.

Have fun !

PS: the error code is “C1853″

Published at DZone with permission of {{ articles[0].authors[0].realName }}, DZone MVB. (source)

Opinions expressed by DZone contributors are their own.

{{ tag }}, {{tag}},

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}
{{ parent.authors[0].realName || parent.author}}

{{ parent.authors[0].tagline || parent.tagline }}

{{ parent.views }} ViewsClicks