Try to format your HD in other PC... or use a boot disk from windows 98 and run FDISK and remove all partition, then format it.
Install the HD in your PC (where it belong originally) and boot using the XP CD and try to format and install windows xp.
I don't know if it will work for you, but I did this on one of my PC a few month back.
If you still encountered the problem, then it might be a motherboard issue (electrical static short during sound card installation etc.) bring it to the repair shop to verify it.
Recently, I installed a sound card, and shortly thereafter I noticed that my computer kept rebooting itself. I tried a lot of things, but nothing worked, so I figured I'd just reformat. I made a bootdisk and booted from it in order to use format.com. I typed in format C:, but it gave me the error that "this program can not be run in DOS mode" (or something similair). So I ended up using Partition Magic from DOS to completely delete my C partition. So I load up the WinXP Pro installation, and I get through formatting the unpartitioned space in the NTFS file format as my C partition. At about 75%, I got the following error message in the form of a dark blue screen with white text (copied word for word):
A problem has been detected and Windows has been shut down to prevent damage to your computer.
The problem seems to be caused by the following file: ntfs.sys
PAGE_FAULT_IN_NONPAGED_AREA
If this is the first time you've seen this Stop error screen, restart your computer. If this screen appears again, follow these steps:
Check to make sure any new hardware or software is properly installed. If this is a new installation, ask your hardware or software manufacturer for any Windows updates you might need.
If problems continue, desable or remove any newly installed hardware or software. Disable BIOS memory options such as caching or shadowing. If you need to use Safe Mode to remove or disable components, restart your computer, press F8 to select Advanced Startup Options, and then select Safe Mode.
Technical information:
*** STOP: 0x00000050 (0xFFFED88D, 0x00000001, 0xF7171AC0, 0x00000000)
*** ntfs.sys - Address F7171AC0 base at F7152000, Date Stamp 3b762863
What I've done -- I disabled BIOS caching and removed the sound card, but neither solved the problem. I'd think that since I removed the sound card and formatted the hard drive, that it certainly couldn't be a driver issue. Either something with the files that Windows setup copying, or a hardware issue (or both). Other than mere speculation, I have no idea what's causing this problem, and that makes it quite hard to remedy. So I'm in urgent need of some help. Is there anything more that I can try, or should I stop eating and save my lunch money for a new computer?
Specs:
Motherboard: Abit NF7
CPU: AMD Athlon XP 3200+
Graphics Card: Atlantis Sapphire RADEON 9600 Pro
Hard Drive: Western Digital 7200RPM, 80gb (purchased not too long ago to replace a 3+ year-old drive that died)
Sound Card: Creative Audigy LS (removed, now trying to use onboard sound)
OS: Windows XP Pro (hopefully)

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic