In a friend's laptop, he has a hard drive with a Windows XP partition. He launched HP Recovery Utility and it deleted his partition and data.
Is there any way to restore all data?
"Recovery utility" may mean a few different things, but a very common meaning is a utility supplied with the machine that reverts the hard drive to its original factory state. This is a second-rate solution (but sadly very common) for people who need to reinstall the operating system etc for any reason. Second rate because you don't get to control the configuration and don't get to select what supplied software to install (or rather, what crapware not to install).
Anyway, this kind of utility literally overwrites data on your hard disk, creating a new partition and writing from an "image" to the hard disk, overwriting whatever was there.
The chances of recovering your previous hard disk data intact are zero, and there should have been a warning to that effect when the recovery utility was run.
However, typically, most unused sectors in the new hard disk state will not be overwritten - they will just not be referenced. So some data from the previous hard disk state may survive in those unused sectors. It may be possible to recover some data.
There are utilities that will help with this search, but I don't know names, links or whatever - mostly they are only of use to criminals, the police, and data recovery specialists. In practice, you would need to send the laptop (or the hard drive, removed from the laptop) to a recovery specialist, pay quite a lot of money, wait quite a long time, and maybe get some useful data back.
In principle, it's possible to do better. When a hard drive overwrites a sector, it doesn't do it perfectly precisely - there is typically a little sliver of the hard disk surface on which the old data is still readable. There are still no guarantees (that sliver may be too thin to read) and this requires extremely expensive specialist equipment that in practice even the police won't use to investigate crimes. Maybe the FBI and CIA do it in a few special cases.
So basically, if you're paranoid about someone else recovering old data from that laptop, there are utilities to wipe the free space of your machine and which can repeatedly write each sector to ensure no previous data is recoverable. There is some reason to worry about wiping free space, but little reason for most of us (even if we have something to hide) to worry about multiple overwrites.
However, if you want to recover data yourself, you can either pay a lot of money or do a lot of research and work for yourself. And you probably won't recover that much useful data. Anything recovered will most likely be in the form of little chunks of data, not intact files, so even when the software has spent all night scanning the hard drive, you'll have days, weeks or months of work figuring out what to do with all those little fragments of text and other data. And you certainly won't be able to recover the complete state of the machine, with software and data intact.
Realistically, the data is gone - you should recover what you can from other sources (downloads you can download again, etc) and accept that the rest is gone.
Unfortunately, most people don't take backups seriously until they've lost valuable data at least once or twice.