Expert adviser licence protection template – expert for MetaTrader 4
You may want to protect your expert adviser project from unauthorized usage if shared by any reason. This guide ‘template’ will guide you ‘how
to’ use three different types of licensing and of course all three can be disabled/enabled.
I’ve seen a lot of community members struggling with this and how to do it and what to use….and remember this is just an example how it could be
done as there are other more advanced methods as well to implement to an expert adviser for this purpose. This one is quite clean and easy, both
in coding + setup and not some rocket science.
Type of restrictions used in this example;
- Account number restriction
- Demo account/real account restrictions
- Date expiry restriction
Explanation how these will work in the adviser
Account number restriction– Example, we don’t want the adviser to work with other account number then specified both in strategy
testing and trading mode
Demo account/real account restrictions– Example, we want to restrict the adviser to either work only on demo or real accounts both
in strategy testing and trading mode.
Date expiry restrictions– Example, in trading mode we want the adviser to only work to a certain date
Adviser settings and behavior
Externally there are no settings and the adviser only send test orders while using strategy tester. Main settings for licence protection can be found
as internal settings within the code it self including explanation how and what to use….Have fun 😉