Thread: problems with I-O

  1. #1
    Registered User
    Join Date
    Oct 2005
    Location
    Brasil
    Posts
    220

    problems with I-O

    Code:
     ofstream out;
        out.open ( c:\\mydir\\Data );
        out<< "teste";
    why this is not working?

  2. #2
    Dragoon Lover wyvern's Avatar
    Join Date
    Jul 2005
    Location
    dragooncity
    Posts
    28
    try this
    Code:
    ofstream getoutofhere ( c:\\mydir\\data );
    getoutofhere << " teste";
    btw:

    "TESTE" ??? u speak portuguese or spanish ??? ( im portuguese and teste is a portuguese word =) ) *just wondering*
    http://img76.imageshack.us/img76/1808/expl7pb.png

    AN EXPLOSION DOESNT HAPPEN CUZ GOD WANTS, IT HAPPENS WHEN A SOMETHING "EXPLODES

  3. #3
    Registered User
    Join Date
    Oct 2005
    Location
    Brasil
    Posts
    220
    hehehe xD eu falo portugues sim ^^ dae mw blz? tu tem msn?

  4. #4
    Registered User
    Join Date
    Aug 2005
    Posts
    1,267
    didn't your compiler generate several errors on the out.open(...) line? you have to enclose the filename in double quotes
    Code:
        out.open ( "c:\\mydir\\Data" );

  5. #5
    Registered User
    Join Date
    Oct 2005
    Location
    Brasil
    Posts
    220
    ok thanks ^^

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. No clue how to make a code to solve problems!
    By ctnzn in forum C Programming
    Replies: 8
    Last Post: 10-16-2008, 02:59 AM
  2. String Manipulation problems -_-
    By Astra in forum C Programming
    Replies: 5
    Last Post: 12-13-2006, 05:48 PM
  3. Rendering problems (DirectX?)
    By OnionKnight in forum Tech Board
    Replies: 0
    Last Post: 08-17-2006, 12:17 PM
  4. contest problems on my site
    By DavidP in forum Contests Board
    Replies: 4
    Last Post: 01-10-2004, 09:19 PM
  5. DJGPP problems
    By stormswift in forum C Programming
    Replies: 2
    Last Post: 02-26-2002, 04:35 PM