Help me code this please

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
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
Fernando Carreiro  
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
Noxtube  
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.

Fernando Carreiro  
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  
it's okay, it's understood, I'm really sorry for this great inconvenience on my part.
Reason: