I am trying to import below
for /F "tokens=2" %%i in ('whoami /user /fo table /nh') do set usersid=%%i echo %usersid% #reg add HKU%usersid%SOFTWAREMicrosoftWindowsCurrentVersionPoliciesSystem /v DisableChangePassword /t REG_DWORD /d 0 /f
but failing as it needs admin right, but when we use rights it changes MY userSID registry not the one who logged in as standard user, any suggestions pls.
I run batchfile as admin but the registryis getting change for admin user not for std users sam tried with HKCU
Source: Windows Questions