title: Unable to Start Program: The system cannot find the file specified. (C++ BTW)
body: <p>Sorry for the copious amounts of comments in the code.  Those are either reminders, notes or failed additions that I want to keep on hand in case I end up using them.  </p>
  
  <p>I have been struggling with this issue since the beginning, and nothing I can do, nor anything I find online has worked.  My code build's fine, with a 100% success, but every time I debug / run my code (This is visual studio 2015 btw) I get this message:</p>
  
  <hr>
  
  <h2>Microsoft Visual Studio</h2>
  
  <p>Unable to start program 'C:\Users\moodyg\Documents\Visual Studio 2015\Projects\floatingballtry2\Debug\floatingballtry2.exe'.</p>
  
  <p>The system cannot find the file specified.</p>
  
  <p>The file is indeed in that location.  I have gone in and checked numerous times, and there is a debug exe file for the code in that exact location.  </p>
  
  <p>Thanks to any and all!</p>
  
  <p>Code:</p>
  
  <pre><code>#include &lt;iostream&gt;
  //#include SerialClass.h
  #include 'stdafx.h'
  using namespace std;
  #define _USE_MATH_DEFINES
  #include &lt;math.h&gt;
  
  #include &lt;stdio.h&gt;
  #include &lt;tchar.h&gt;
  //#include "SerialClass.h"  // Library described above
  #include &lt;string&gt;
  
  //#include "LpmsSensorManagerI.h"
  //include "LpmsSensorI.h"
  
  using std::cout;
  using std::endl;
  
  
  //LpmsSensorManagerI* manager = SensorManagerFactory();
  
  //LpmsSensorI* lpms = manager-&gt;addSensor(DEVICE_LPMS_B,'00:11:22:33:44:55');
  
   void main() {
  
       //Serial* SP = new Serial("\\\\.\\COM3");    // adjust as needed
  
       //a = arduino('com4', 'UNO');
  
      bool isspinning = true;
  
      int moz = 4;
  
      int moth = 0 ;
  
      int moph = 0;
  
      //set water release time
  
      while (isspinning == true) {
  
          //pitch = lpms-&gt;GET_PITCH();
  
          //yaw = lpms-&gt;GET_YAW();
  
          //moth += yaw;
          //moph += pitch;
  
          if (moth &gt; (2 * M_PI)) {
  
              moth = 0;
  
          }
  
          if (moph &gt; (2 * M_PI)) {
  
              moph = 0;
  
          }
  
          cout &lt;&lt; "Radius: " + moz &lt;&lt; endl;
          cout &lt;&lt; "Theta: " + moth &lt;&lt; endl;
          cout &lt;&lt; "Phi: " + moph &lt;&lt; endl;
  
          if (moth &gt;= (M_PI / 2) - (M_PI / 8) &amp;&amp; moth &lt;= (M_PI / 2) + (M_PI/                                                                             
          8))                  
          {
  
          if (moph &gt;= (M_PI / 2) - (M_PI / 8) &amp;&amp; moph &lt;= (M_PI / 2) + (M_PI /         
          8)) 
          {
  
                  //release water
  
                  isspinning = false;
  
              }
  
          }
  
          else {
  
              isspinning = false;
  
          }
  
      }
  
      cout &lt;&lt; "Radius: " + moz &lt;&lt; endl;
      cout &lt;&lt; "Theta: " + moth &lt;&lt; endl;
      cout &lt;&lt; "Phi: " + moph &lt;&lt; endl;
  
  }
  </code></pre>