setting environmental variables with *.ini files or with the registry?

  • Thread starter Thread starter yawnmoth
  • Start date Start date
Y

yawnmoth

Some dll's that I'm using in an application of mine require an
environmental variable be set. I, however, would prefer not to set a
global one. I could do it locally, via a *.cmd file, and require that
that *.cmd file be ran, but I'm wondering if maybe there's a better
way? A registery setting or some sort of *.ini setting that could be
used to set environmental variables for specific programs?
 
yawnmoth said:
Some dll's that I'm using in an application of mine require an
environmental variable be set. I, however, would prefer not to set a
global one. I could do it locally, via a *.cmd file, and require that
that *.cmd file be ran, but I'm wondering if maybe there's a better
way? A registery setting or some sort of *.ini setting that could be
used to set environmental variables for specific programs?

Environmental variables are there for everyone in a given process
to see and to use, not just for specific programs. If don't want to
set one globally then you can set one for the ***current process***,
by launching your application through a batch file whose first
command is to set the desired variables. They will, of course,
be invisible to other processes.
 

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

Back
Top