title: Error while building Net Application in Visual Studio 2012
body: <p>The following few lines of my code are giving errors :</p>
  
  <pre><code>#include "stdafx.h"
  #include &lt;tchar.h&gt;
  #include &lt;windows.h&gt;
  #include &lt;iostream&gt;
  #include &lt;fstream&gt;
  #include &lt;mmsystem.h&gt;
  
  using namespace System;
  using namespace std;
  
  #pragma comment(lib, "winmm.lib")
  
  int main()
  {...
  </code></pre>
  
  <p>The code is suppose to work using Windows SDK so I added property pages accordingly</p>
  
  <p>But while building in Visual Studio 2012 gives following errors :</p>
  
  <pre><code> error C1083: Cannot open include file: 'stdafx.h': No such file or directory   4
  
  3   IntelliSense: name must be a namespace name 11
  4   IntelliSense: name followed by '::' must be a class or namespace name 140
  5   IntelliSense: expression must have class type   140
  6   IntelliSense: name followed by '::' must be a class or namespace name 141
  9   IntelliSense: identifier "S" is undefined       145
  </code></pre>