I take no credit whatsoever for the work done by this guy "sieempi" on XDA Developers Forum... I found it whilst searching on the internet to unlock my HTC Desire (the original Desire model) and found the below. It works for me and many other users, so use it on your own...

So here it goes:

SIM-Unlock Utility v0.2a

THIS APP IS FREEWARE! Commercial use is forbidden!

Burn the iso, boot it, power up your phone into HBOOT by pressing both Vol-Down and Power and follow the instructions.

The app doesn't require root or s-off and should work on any hboot and radio version. (it has been tested so far with HBOOT up to 0.93.1000 and RADIO up to 5.14.05.17).

It's based on some vulnerabilities and undocumented features, so disclosing them would mean the greater the chance of them being corrected.
I've only tested it on Desire GSM and I do not recommend using it on CDMA devices; doing otherwise could lead to unpredictable results.

Download links:
http://www.multiupload.com/LWMKK7CG02

http://www.fileshare.ro/15190855056.1

If you like free software and find this tool useful, Paypal me a beer, it helps development a lot..

Enjoy!