#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2005
    Posts
    32
    Rep Power
    15

    Can not find <fstream.h>?


    I'm trying to write to a file, but when I compile my app, it gives me this:
    Code:
    c:\Documents and Settings\DarkLord\My Documents\Visual Studio Projects\thebank\thebank.cpp(2): fatal error C1083: Cannot open include file: 'fstream.h': No such file or directory
    And this is what I'm including:
    Code:
    #include <fstream.h>
    I've tried google, msdn and searched here. This is driving me nuts, please help.
  2. #2
  3. Banned ;)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2001
    Location
    Woodland Hills, Los Angeles County, California, USA
    Posts
    9,782
    Rep Power
    4301
    Try using fstream instead of fstream.h.
    Code:
    #include <fstream>
    using namespace std;
    Up the Irons
    What Would Jimi Do? Smash amps. Burn guitar. Take the groupies home.
    "Death Before Dishonour, my Friends!!" - Bruce D ickinson, Iron Maiden Aug 20, 2005 @ OzzFest
    Down with Sharon Osbourne

    "I wouldn't hire a butcher to fix my car. I also wouldn't hire a marketing firm to build my website." - Nilpo
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2005
    Posts
    32
    Rep Power
    15
    Originally Posted by Scorpions4ever
    Try using fstream instead of fstream.h.
    Code:
    #include <fstream>
    using namespace std;

    Alright..I could have sworn I tried that..But this time it worked.. Thanks :D

IMN logo majestic logo threadwatch logo seochat tools logo