fstream.h in .Net 2003

  • Thread starter Thread starter dave
  • Start date Start date
D

dave

Trying to compile a project created by V Studio 6.0 and
compiled then with .Net 2002, I have a problem with 2003
Compiler could not find fstream.h :
line #include <fstream.h> gives fatal error.

How to fix it.
Thanks
 
I tried to use :#include <iostream> using namespace std;
but then had a problem defining "istream file"
error C2079: 'CAlgoticksDoc::m_InRuleTextFile' uses
undefined class 'std::basic_ifstream<_Elem,_Traits>'

Thanks
 
You're on the right track. You need to #include <fstream> (no .h) though.
-cd
 
dave said:
I tried to use :#include <iostream> using namespace std;
but then had a problem defining "istream file"
error C2079: 'CAlgoticksDoc::m_InRuleTextFile' uses
undefined class 'std::basic_ifstream<_Elem,_Traits>'

#include <fstream>
 
Brad said:
<fstream.h> is deprecated and no longer available with the latest
compilers. All it did (or should have done ) was load <fstream> for
you and lift it into the global namespace.

Conceptually that's almost true, but in fact the IOStreams implementation
usually provided by <fstream.h> differed from standard IOStreams is several
fundamental ways.

- It was not standardized.
- It was not template-ized.
- There were a variety of differences in the details of opening files.
- There were differences in the handling of locales.

-cd
 
<fstream.h> is deprecated and no longer available with the latest compilers.
All it did (or should have done ) was load <fstream> for you and lift it
into the global namespace.
 
Back
Top