This:
ios_base::open_mode Mode = std::ios_base::in | std::ios_base::binary;
should be:
std::ios_base::openmode Mode = std::ios_base::in | std::ios_base::binary;
Note the lack of _
in openmode
.
(I had to add these lines and put your code in a function to get your snippet to compile.
#include <string>
#include <fstream>
using std::string;
using std::ofstream;
using std::ios_base;
)
Charles Bailey
2010-06-03 20:07:57