Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

View environment variable of process on Windows

Tags:

windows

How do I view the environment variable of a Windows process? Looking for Windows equivalent for something like environ file in procfs on Unix.

like image 571
theactiveactor Avatar asked Feb 13 '10 00:02

theactiveactor


People also ask

How do I display environment variables?

To display the values of environment variables, use the printenv command. If you specify the Name parameter, the system only prints the value associated with the variable you requested.

Where are environment variables stored on Windows?

Machine environment variables are stored or retrieved from the following registry location: HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\Environment . Process environment variables are generated dynamically every time a user logs in to the device and are restricted to a single process.


2 Answers

Process Explorer or one of its friends should help.

like image 112
ziya Avatar answered Sep 20 '22 07:09

ziya


Check out GetEnvironmentStrings.

like image 28
John Feminella Avatar answered Sep 21 '22 07:09

John Feminella