You have indicated to your IDE that you are using precompiled headers, but actually you are not. Find the setting that indicates you are using precompiled headers, and change it to indicate that you are not.
Alternatively, take the advice of the error message and stick #include "StdAfx.h" at the top of your code.