title: LNK1201 on Visual C++ 2003
body: <p>I keep getting this error message as a result after every Debug run I have done on any of my projects in VS2003.
  I have browsed around many forums and they all provide an answer that does not fit to the actual problem.</p>
  
  <blockquote>
    <p>LINK : fatal error LNK1201: error writing to program database 'd:\Coding\Flyff\Projects\GUI System 20110721\Debug\GUI System 20110721.pdb'; check for insufficient disk space, invalid path, or insufficient privilege</p>
  </blockquote>
  
  <p>I'm using Windows 7 Ultimate x64 with Visual Studio 2003 .NET (service pack VS7.1sp1-KB918007-X86.exe).</p>
  
  <p>What I have tried already:  </p>
  
  <ul>
  <li>Run in compatible mode for several other operative systems and service packs.  </li>
  <li>Set project folders write permission to full.  </li>
  <li>Run Visual Studio as Administrator.  </li>
  <li>Edited Debug Information Format to several other formats.</li>
  </ul>
  
  <p>To reproduce this bug, you must have Windows 7 x64 (probably Ultimate).
  Visual Studio 2003 (with VS7.1sp1-KB918007-X86.exe update).</p>
  
  <p>I have over 150 GB space so it has nothing to do with that.</p>
  
  <p>Visual Studio simple locks the PDB file when debugging, and after debug it cannot unlock it.</p>
  
  <p>You must also run a code piece that is running for a few seconds, such as this:</p>
  
  <pre><code>int APIENTRY WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine,     int nCmdShow )
  {
      Sleep( 5000 );
      MessageBox( NULL, "Test", "", 0 );
      return 0;
  }
  </code></pre>
  
  <p>Hope anyone have a solution, as I'm currently required to use this environment configuration.</p>
  
  <p>Cheers, Nicco.</p>