How to access and environment varible from inside a program.

  • Thread starter Marcio DeBarros
  • Start date
M

Marcio DeBarros

Hi,

I would like to know if it possible to have access to an environment
variable from inside a program at run time. What I am trying to do,
is to be able to set different paths for files that are required for
my application and depending on each user's environment to have access
to the from a predetermined environment variable.
E.g.: output files will be saved to a directory called /data/out,
so I would require each client to the application of set a env. variable
called OUTPUT, and then I would save them to that location. Also if this
is possible, would it work across platforms (Linux, Windows, etc... ?)

Thanks in advance for any help.

--MD
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top