The Microsoft Input/Output Stream Classes (iostream.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
ifstream::open
ifstream                                    Up Contents Index Back
──The Microsoft iostream Classes────────────────────────────────────────────
 
  void open( const char* szName, int nMode = ios::in,
             int nProt = filebuf::openprot );
 
  Parameter   Description
 
  <szName>    The name of the file to be opened during construction.
 
  <nMode>     An integer containing bits defined as ios enumerators that
              can be combined with the OR (|) operator. See the
              ifstream constructor for a list of the enumerators. The
              ios::in mode is implied.
 
  <nProt>     The file protection specification; defaults to the static
              integer filebuf::openprot. See the ifstream constructor
              for a list of the other allowed values.
 
  Remarks
 
  Opens a disk file and attaches it to the stream's filebuf object. If the
  filebuf object is already attached to an open file, or if a filebuf call
  fails, the ios::failbit is set. If the file is not found, then the
  ios::failbit is set only if the ios::nocreate mode was used.
 
  See Also
 
  filebuf::open, ifstream::ifstream, ifstream::close,
  ifstream::is_open
 
 
                                     -♦-