Don't format, what happens is that some viruses and sometimes legitamate programs change the logon program.
Download and create a bootable CD from http://www.pcregedit.com/
In the registry edit, find this:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon.
In the right pane under Userinit, Change the key to read:
C:\Windows\System32\Userinit.exe, <-- include the comma.
Reboot PC, and you should be able to logon.