Drawdown profit per day

 
Hello, I have a question regarding the principle of drawing and profit per day, I would like if for example we reach 4% gain or if we reach 4% loss the EA does not open any trades until the next day how to do it thank you.
 
Your topic has been moved to the section: Expert Advisors and Automated Trading
Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893
MQL5 forum: Expert Advisors and Automated Trading
MQL5 forum: Expert Advisors and Automated Trading
  • www.mql5.com
How to create an Expert Advisor (a trading robot) for Forex trading
 
ANK KERD7: Hello, I have a question regarding the principle of drawing and profit per day, I would like if for example we reach 4% gain or if we reach 4% loss the EA does not open any trades until the next day how to do it thank you.

You will have to code that into your EA. You will have to monitor your daily limits, and then program it's logic not to place any more trades until the next day.

Search the CodeBase as there should be a few examples of how to monitor the drawdown.

 
  • Usually people who can't code don't receive free help on this forum.
  • If you show your attempts and describe your problem clearly, you will most probably receive an answer from the community. Use the CODE button (Alt-S) when inserting code.
  • To learn MQL programming, you can research the many available Articles on the subject, or examples in the Codebase, as well as reference the online Documentation.
  • If you do not want to learn to code, that is not a problem. You can either look at the Codebase if something free already exists, or in the Market for paid products (also sometimes free). However, recommendations or suggestions for Market products are not allowed on the forum, so you will have to do your own research.
  • Finally, you also have the option to hire a programmer in the Freelance section.
 
Fernando Carreiro #:
  • Usually people who can't code don't receive free help on this forum.
  • If you show your attempts and describe your problem clearly, you will most probably receive an answer from the community. Use the CODE button (Alt-S) when inserting code.
  • To learn MQL programming, you can research the many available Articles on the subject, or examples in the Codebase, as well as reference the online Documentation.
  • If you do not want to learn to code, that is not a problem. You can either look at the Codebase if something free already exists, or in the Market for paid products (also sometimes free). However, recommendations or suggestions for Market products are not allowed on the forum, so you will have to do your own research.
  • Finally, you also have the option to hire a programmer in the Freelance section.

I know how to code I just don't know how to code this thing exactly.

Auto-translation applied by moderator. On the English forum, please write in English.

 
ANK KERD7 #: I know how to code I just don't know how to code this thing exactly.

As already stated, you can study the example code in CodeBase and Article publications, and then attempt to code it yourself.

Then you can present your attempted code and describe the specifics of which you need guidance on. We are not going to code it for you.

Another option is to hire someone in the Freelance section, to code it for you, so that you can then learn from their code.

 
Fernando Carreiro #:

As already stated, you can study the example code in CodeBase and Article publications, and then attempt to code it yourself.

Then you can present your attempted code and describe the specifics of which you need guidance on. We are not going to code it for you.

Another option is to hire someone in the Freelance section, to code it for you, so that you can then learn from their code.

But who talked to you about coding for me I only ask for information and I just specify what I want to do apart from disturbing me you bring me nothing

Auto-translation applied by moderator. On the English forum, please write in English.

 
ANK KERD7 #:

Auto-translation applied by moderator. On the English forum, please write in English.

Please write in English, not in French. This is the English forum. Either use the automatic translation tool, or post in one of the other language forums.

ANK KERD7 #: But who talked to you about coding for me I only ask for information and I just specify what I want to do apart from disturbing me you bring me nothing

I have already stated that you can find examples of code in the CodeBase or in the Articles section which you can study and learn from.

You need to put in the effort and do your research.

Click on the link CodeBase and then fill in the search words and see what it finds. Examples of keywords can be "close all on loss" or "close all on profit".