I suspect that you have corrupt files as a result of the hard shutdowns.
If you have the installation disc do a Repair Installation.
Boot the computer from the XP CD. You may need to change boot order in the BIOS so that the CD-ROM is the first device in the boot order.
When you see the "Welcome To Setup" screen, you will see the options below.
This portion of the Setup program prepares Microsoft Windows XP to run on your computer:
To setup Windows XP now, press ENTER.
To repair a Windows XP installation using Recovery Console, press R.
To quit Setup without installing Windows XP, press F3.
Press Enter to start the Windows Setup.
To setup Windows XP now and Repair Install , press ENTER.
You do not want to choose "To repair a Windows XP installation using the Recovery Console, press R.
Accept the License Agreement and Windows will search for existing Windows installations.
Select the XP installation you want to repair from the list and press R to start the repair. If Repair isn't one of the option end the installation, this will mean that you will need to do a fresh installation of XP.
The repair will copy the necessary files to the hard drive and reboot, the repair installation will continue after the reboot.