Here's a simple instruction on how to full reset and restore to factory settings the LG Optimus GT540.
NOTE: Performing a had reset will delete all of your data and installed applications on the device.
Do a back up copy of all any important data and files you want to keep before you do a hard reset.
LG GT540 hard reset LG Optimus full reset
Press both VOLUME UP + HOME + SEARCH buttons simultaneously for about 5 seconds.
Then the phone will then reboot and restore to its original factory default settings.