Maybe a good service to protect your codes :
MQL Defender - Home page
The best way to protect your code
The best way is to simply keep it private and don't share it. Don't tell anyone you have it, especially people who can have physical access to your computer.
If you want to sell it then you obviously must have a good EA, so you don't need to sell it. If it isn't then your obviously trying to make easy money from selling duff EA's and trying to scam people.
If you do want to protect your EA, then the best way is with a dll. Code the EA to communicate with your servers and tell you who is using your expert and allow you to block trading.
You could also use passwords, or keys. E.g. unique keys calculated mathematically using unique fields such as account number, etc.
I agree that the best way of code protection is putting the main functionality part to the DLL. Though you can also put it on the SERVER side.
Tags for this Thread