You need to boot from the Windows cd and the boot order in the bios must have the cd first.
From Fred Langa:
Enter The Recovery Console
The safest, surest way to resolve problems such as "Missing or corrupt HAL.DLL," "Invalid Boot.Ini," or "Windows could not start..." is to boot the PC from an XP Setup CD and use the pristine, uncorrupted files and tools there to effect repairs. The one catch is that if your setup CD is significantly older than your current Windows version, you may have file compatibility problems. For example, you can hit snags if you use an original or SP1 XP Setup CD to try to repair an XP SP2 installation
. You'll get a message to the effect that the version you're trying to upgrade is newer than the version on the CD.The solution here is to use a "slipstreamed" setup CD, which adds the newer files to your original setup CD.
This kind of updated setup CD can be used on just about any XP installation. It's a good idea to have an up-to-date, slipstreamed setup CD available in any case, as it simplifies all future installs and CD-based repairs.
Once you have a startup CD with the same version of system files as the PC you're working on, configure your PC to boot from CD if it isn't already set up that way. (You may need to enter the BIOS setup tool to configure the PC to boot from the CD.)
Start your PC with the XP Setup CD in the drive. When you see the "Press any key to boot from CD..." prompt, do so and let the CD-based boot process begin.
When the Recovery Console option is offered ("Press R to start the Recovery Console"), do so. You may be asked which Windows installation to enter, in which case type the number of the Windows installation you wish to work on (usually "1").
When prompted, enter the Administrator's password for that Windows installation.
At the command prompt, type "Bootcfg /Rebuild" (without the quotes) and hit enter. Windows will then scan the hard drive, looking for valid Windows installs and startup information.
How to make a slipstreamed CD:http://www.theeldergeek.com/slipstreamed_xpsp2_cd.htm