Changing System Environment Variables on Windows - Dave's Blog

Search
My timeline on Mastodon

Changing System Environment Variables on Windows

2012 Mar 16, 3:13

Is this really the right way to do this? Feels icky:

To programmatically add or modify system environment variables, add them to the HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\Environment registry key, then broadcast a WM_SETTINGCHANGE message with lParam set to the string “Environment”.

PermalinkCommentsprogramming techncial registry environment-variable windows
Older Entries Creative Commons License Some rights reserved.