Re: I need some ideas on how to go about creating files....
- From: K-mart Cashier <cdalten@xxxxxxxxx>
- Date: Thu, 28 Jun 2007 19:54:50 -0700
On Jun 28, 7:32 pm, Eric Sosman <esos...@xxxxxxxxxxxxxxxxxxx> wrote:
K-mart Cashier wrote:
Program A reads in a file. However, Program A dictates the the person
creates an input file. After the person creates the file, they have to
change the following lines to the path of the file they created.
#define PATH "/home/calten/run/data"
Now, there has to be some better way than just having the user edit
the source code and recompile it everytime they want to change the
file name.
I'm sure there is something pretty obvious that I missed. Ideas?
Input redirection, command-line arguments, environment
variables, prompt-and-response, ...
--
Eric Sosman
esos...@xxxxxxxxxxxxxxxxxxx
I'm not too sure how I would go about this using environment
variables. I guess it's time for me to crack out "Unix Programming for
minimum wage clerks that got rejected twice by UC-Berkeley."
.
- Follow-Ups:
- Re: I need some ideas on how to go about creating files....
- From: Rainer Weikusat
- Re: I need some ideas on how to go about creating files....
- From: K-mart Cashier
- Re: I need some ideas on how to go about creating files....
- References:
- I need some ideas on how to go about creating files....
- From: K-mart Cashier
- Re: I need some ideas on how to go about creating files....
- From: Eric Sosman
- I need some ideas on how to go about creating files....
- Prev by Date: Re: I need some ideas on how to go about creating files....
- Next by Date: Re: I need some ideas on how to go about creating files....
- Previous by thread: Re: I need some ideas on how to go about creating files....
- Next by thread: Re: I need some ideas on how to go about creating files....
- Index(es):
Relevant Pages
|