Thursday, 2 June 2011

fatal error C1083: Cannot open include file: "fstream.h": No such file or directory fix

The fstream.h header (and some other similar ones like iostream.h) does not exist anymore. It was part of the old iostream library and it was non standard. The replacement is fstream (without .h extension):
#include <fstream>
using namespace std; // you also need this because the standard stuff is declared in the std namespace

No comments:

Post a Comment