How to change the default logon name on Windows 7

On a remote PC it was another logon name that appeared by default… In that case I had to click on « Switch User », then « Other User », and finally enter my username and password. Very frustrating.

After a few searches I found we can change the default name using the registry and with the below commands (to enter into a cmd console in admin mode) :
call reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI" /v LastLoggedOnSAMUser /t REG_SZ /d "The_Default_Domain\The_Default_Username" /f
call reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI" /v LastLoggedOnUser /t REG_SZ /d "The_Default_Domain\The_Default_Username" /f

Log off and The_Default_Domain\The_Default_Username should prompt!

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *

*