Good afternoon, Vladimir. Is it possible to implement the function of enabling only Buy or Sell in this Expert Advisor? I want to try to run the Expert Advisor on two charts, one for Buy and the other for Sell. Will it work if I change one of the selected parameters true to false?
if(ma[0]<ma[1] && ma[1]<ma[2] && ma[2]<ma[3]) // trend down { if(m_symbol.Bid()>ma[0]) m_need_open_sell=true; } else if(ma[0]>ma[1] && ma[1]>ma[2] && ma[2]>ma[3]) // trend up { if(m_symbol.Ask()<ma[0]) m_need_open_buy=true; }
Good afternoon, Vladimir. Is it possible to implement the function of enabling only Buy or Sell in this Expert Advisor? I want to try to run the Expert Advisor on two charts, one for Buy and the other for Sell. Will it work if I change one of the selected parameters true to false?
Vladimir Karputov #:
Это грубо, но сработает. Конечно лучше добавить входной параметр.
Can you modify the EA on a financial basis to enable only buying or only selling in the settings? For example, as in this EA of yours https://www.mql5.com/en/code/16728
- www.mql5.com
Can you modify the EA on a financial basis to enable only buying or only selling in the settings? For example, as in this EA of yours https://www.mql5.com/en/code/16728
I have run the tests, it seems to work, put it on a demo account and see what happens.
the pictures of the sell entry in the description do not match this condition:
if(count_buys+count_sells==0) // no open positions { m_lot=InpStartLots; if(ma[0]<ma[1] && ma[1]<ma[2] && ma[2]<ma[3]) // trend down { if(m_symbol.Bid()>ma[0]) m_need_open_sell=true; } else if(ma[0]>ma[1] && ma[1]>ma[2] && ma[2]>ma[3]) // trend up { if(m_symbol.Ask()<ma[0]) m_need_open_buy=true; } }
Very nice EA, well done.
Do you have the same for a netting account?
Thank you
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Ilan iMA:
Ilan based on indicator iMA (Moving Average, MA)
Author: Vladimir Karputov