Help me code this please

 
Hello my friends,

I want to code a function that takes a trade if the current price goes up one or more ticks,

but when it goes down a trick it takes the position directly.

As you can see from the illustration in the attached image.

Here is my algorithm
If Current Price < Lowest price {
      if Current Price goes down even one tick {
            Tack a SELL
} }

I can't. Any help please,
Thanks in advance
Files:
aide.PNG  18 kb
 
Noxtube: Hello my friends, I want to code a function that takes a trade if the current price goes up one or more ticks, but when it goes down a trick it takes the position directly. As you can see from the illustration in the attached image. Here is my algorithm. I can't. Any help please, Thanks in advance

Your "strategy" is explained at a very high level. Achieving it in MQL5 code requires many lines of code, especially if you are using tick data instead of OHLC bar data.

It seems that you have not yet reached a sufficient level of MQL coding skill that will allow you to understand any answer we give you.

May I suggest that you hire someone in the Freelance section to code it for you and you then study their code to understand how it is done?

Trading applications for MetaTrader 5 to order
Trading applications for MetaTrader 5 to order
  • 2022.08.23
  • www.mql5.com
The largest freelance service with MQL5 application developers
 
Fernando Carreiro #:

Your "strategy" is explained at a very high level. Achieving it in MQL5 code requires many lines of code, especially if you are using tick data instead of OHLC bar data.

It seems that you have not yet reached a sufficient level of MQL coding skill that will allow you to understand any answer we give you.

May I suggest that you hire someone in the Freelance section to code it for you and you then study their code to understand how it is done?

Thank you for your reaction, but I don't have the money to pay these freelancers,

I know that here in this forum there are experts, extremely intelligent people who can solve this problem, that's why I launched my problem here.

 
Noxtube #: Thank you for your reaction, but I don't have the money to pay these freelancers, I know that here in this forum there are experts, extremely intelligent people who can solve this problem, that's why I launched my problem here.

On this forum, there may be "experts, extremely intelligent people who can solve this problem", but that does not mean we are going to code it for you for free,

If you put in the effort to learn for yourself, and show your attempt and request only guidance from us, then that will be welcomed, but we will not be coding it for you.

I wish all the best on your journey!

 
Noxtube #: but I don't have the money to pay these freelancers,

So you want a slave, to code it for you, for free? Sorry, the world doesn't do that anymore. Learn to code, or pay someone.

You “don't have the money,” so how do you expect to fund a trading account?

 
it's okay, it's understood, I'm really sorry for this great inconvenience on my part.
Reason: