basic question

This is a discussion on basic question within the C++ Programming forums, part of the General Programming Boards category; i am attempting to write my first program and have been reading for about 1 month now for some preliminary ...

  1. #1
    Registered User
    Join Date
    Dec 2003
    Posts
    2

    basic question

    i am attempting to write my first program and have been reading for about 1 month now for some preliminary foundation however, i have not read anywhere how to save the input from my program and save it as a .cfg to a user defined location. i can set my locations i believe but i have not learned how to save the input and how to define the type of file it saves as.
    im sorry if this is a repeat thread, i have't seen one similar yet.

  2. #2
    Senior Member joshdick's Avatar
    Join Date
    Nov 2002
    Location
    Phildelphia, PA
    Posts
    1,146
    Read up on the <fstream> library. That allows you to open files for input or output.
    FAQ

    "The computer programmer is a creator of universes for which he alone is responsible. Universes of virtually unlimited complexity can be created in the form of computer programs." -- Joseph Weizenbaum.

    "If you cannot grok the overall structure of a program while taking a shower, you are not ready to code it." -- Richard Pattis.

  3. #3
    Kiss the monkey. CodeMonkey's Avatar
    Join Date
    Sep 2001
    Posts
    920
    fstream.. it's all in the fstream... do DOOOOOOO dooooo...........
    After reading this:
    http://www.cprogramming.com/tutorial/lesson9.html
    Read these:
    http://www.cprogramming.com/tutorial/lesson10.html
    http://faq.cprogramming.com/cgi-bin/...&id=1043284392
    *edit*Beat me to it you bastard!*edit*
    Last edited by CodeMonkey; 12-29-2003 at 01:31 AM.
    "If you tell the truth, you don't have to remember anything"
    -Mark Twain

  4. #4
    Registered User
    Join Date
    Dec 2003
    Posts
    2
    thank you for responding guys.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. A basic math programming question
    By hebali in forum C Programming
    Replies: 38
    Last Post: 02-25-2008, 04:18 PM
  2. Basic question about GSL ODE func RK4
    By cosmich in forum Game Programming
    Replies: 1
    Last Post: 05-07-2007, 03:27 AM
  3. Basic question about RK4
    By cosmich in forum C++ Programming
    Replies: 0
    Last Post: 05-07-2007, 03:24 AM
  4. A very basic question
    By AshFooYoung in forum C Programming
    Replies: 8
    Last Post: 10-07-2001, 04:37 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21