The older standards of c++ require you pass a const char*
parameter to the std::fstream::open()
method. You can just write
inout.open(std::string(newFolder + "/" + two).c_str(),ios::out);
or for windows file system
inout.open(std::string(newFolder + "\\" + two).c_str(),ios::out);