I want to add an user variable using setx.
I tried:
setx LOL abcd
> SUCCESS: Specified value was saved
echo %LOL%
> %LOL%
Why it does not set an user variable? I expected:
echo %LOL%
> abcd 
Why setx command does not set an user variable?
Because that is the way it works.
setx will change the environment variable you specify for future sessions. Use set to set for the current and new child processes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With