Cannot Output Data Into a Text File
<p>I am experimenting with some code for outputting information to a file.  The file address appears to be correct and the code compiles but the file never populates.  Can you see a problem?</p>

<pre><code>#include "stdafx.h"
#include &lt;iostream&gt;
#include &lt;fstream&gt;
#include &lt;string&gt;
#include &lt;sstream&gt;

using namespace std;

int main()
{
    int size = 10;
for(int i=0; i&lt;size; ++i)
{
    ofstream outputfile;
    outputfile.open("C:MyFolder\outputfile.txt", ios::app);
    outputfile &lt;&lt; "SYMBOL, STOCK_PRICE" &lt;&lt; endl;
    outputfile &lt;&lt; i &lt;&lt; endl;
    outputfile.close();
}

}
</code></pre>
