A guy brought me an old HP Vectra VL420MT. McAfee antivirus had told him it needed to change a registry value (Yes|No) and he hit No. From that point on, every time he logged on it said Loading your Settings, then immediately logged him off.
He'd bought the machine from some guy who didn't give him the Windows or Office CDs. There was no recovery partition so a CD was needed. With an HP you have to use the CD that came with it or one for a very similar system or Microsoft won't Activate Windows (and it doesn't give you 30 days either - it wants it NOW).
Research indicated it was probably the registry failing to ask for or get Windows/system32/userinit.exe. The usual post virus clean-up fix (copy userinit.exe wsaupdate.exe) didn't work.
So how do you edit the registry of a machine you can't log into?
Well I found Bart's Preinstalled Environment (BertPE). I installed it on my
Windows 2000 machine and had it build a boot disk image from a Windows XP Pro distribution disk and burned a CD.
It booted right up and I ran regedit. Mounted the hard disk's HKEY_USERS under the CDs
HKEY_USERS and went to the Winlogin key. Found Userinit wasn't there at all so I created the key, unmounted the hard disk's registry and rebooted. Voila! login.