Why doesn't environment variable get updated in cmd without restart?
- by John Nevermore
CMD commands:
setx SOMEVARIABLE "newpath" /M
setx SOMEVARIABLE "%SOMEVARIABLE%;newpath2" /M
Expected output on ECHO %SOMEVARIABLE%:
newpath;newpath2
Actual output:
%SOMEVARIABLE%
Actual value stored (From System Properties-Environment Variables GUI):
%SOMEVARIABLE%;newpath2
The only way i can get the expected output is, if i restart the…