Too many failed attempts trying to reset iphone back to factory setting?

I'm trying to reset my iphone but i keep getting the code wrong, i tried to enable the erase data after 10 attempts but nothing is happening. What can i do?

Unfortunately if you don't know your code you can't do much other than get a new iPhone. They put those protections in to discourage people from stealing phones.

Yet another reason to get an Android.

If you are the original purchaser and can prove legal ownership then an Apple Genius Bar or an Apple authorised repair centre can reset the iphone for you back to factory specs.

It isn't free, you do need to provide solid proofs of your address and identity (which will be copied and held on file).

If you can't use that method then you now own a useless brick. You should have stopped trying when the phone warned you what would happen next. That way, if you did suddenly remember the correct security credentials, you could have recovered use of the phone.

It may seem harsh, but it has to be that way to make stolen Apple products as useless as possible to thieves. Apple do provide legitimate users with a number of ways to regain use of their items using alternative methods before they end up locking themselves out of their devices. So you could have asked for a reset using an alternative email address, or for a reminder of your Apple username.

Go to the apple store and spend a barrel of money.