Well, once you've finished giving your "idiot friend" a good old slap about
the head with a wet kipper, you're probably going to have to do a repair
installation. This is a non-destructive process though it IS advisable to
backup important data beforehand.
Boot from your XP disc and proceed as if you were installing it fresh, it
will then detect the existing installation of Windows and ask if you want to
repair it, choose YES and it will reinstall Windows over the top (leaving
existing programs alone) and then allow you to enter your product key.
Once you've reinstalled, you might still have to activate by phone, if so,
it's a free call so just tell them that you had to reinstall it on the same
computer and they'll give you a new activation code... just don't mention
what your friend did!
Rick's advice would normally correct an occaisional bug with the activation
system IIRC, but as your friend used a crack, it probably won't work.
Hopefully this will fix your problem for you and don't let your friend on
your PC again!
Lorne