Dmitri,
In the section of the MSDN documentation titled "Environment Variables"
(located at
http://msdn.microsoft.com/library/de...variables.asp),
it states:
To programmatically add or modify system environment variables, add them to
the HKEY_LOCAL_MACHINE\System\CurrentControlSet\Contro l\Session
Manager\Environment registry key, then broadcast a WM_SETTINGCHANGE message.
This allows applications, such as the shell, to pick up your updates.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Dmitri Shvetsov" <ds*******@cox.net> wrote in message
news:D5pnb.89253$Ms2.60118@fed1read03...
Hi,
Does somebody know how to create a new EnvironmentVariable, not only for a
current session, but a global?
I need to write something like an installation program and I want to add
several global system variables for my application and a database. How can
I do that?
Thanks.
Dmitri S.