fxcodebase-backup

If_Then_order

Source: https://fxcodebase.com/code/viewtopic.php?f=38&t=67329
Forum: 38 · Topic 67329 · 7 post(s)


If_Then_order

Apprentice · Thu Feb 07, 2019 5:11 pm

Based on request. viewtopic.php?f=27&t=67324

If Then Order Statement.png

If_Then_order.mq4


Re: If_Then_order

Fx4mt.com · Fri Feb 08, 2019 8:55 pm

Thank you! Can you elaborate on the Magic Number?

Much appreciated! Very excited to try this out. Very grateful.


Re: If_Then_order

Apprentice · Sat Feb 09, 2019 4:43 am

https://docs.mql4.com/trading/ordersend Order magic number. May be used as user defined identifier.

The unique ID can come in handy if you have a more then one active strategy.


Re: If_Then_order

rudyyy · Sun Feb 10, 2019 6:06 am

oh. my. gosh.

I’ve been wanting something like this for months and I just happen to stumble upon this site THREE DAYS after you post this?!?!

THANK YOU!


Re: If_Then_order

rudyyy · Tue Feb 12, 2019 5:55 am

Hi Apprentice,

I was testing this out today and noticed a few times that a trade would not trigger. Is there a min distance that a price trigger needs to be from current price when the EA is activated? Obviously outside the spread, but even a few pips away it was still giving me issues. Im not sure what caused certain orders to activate and others not.

Any feedback or tips would be appreciated


Re: If_Then_order

Apprentice · Thu Feb 14, 2019 6:06 am

Can you provide a trading log? EA will print the reason why the order was not created.


Re: If_Then_order

Fx4mt.com · Mon Feb 18, 2019 5:55 pm

Hi Apprentice, he and I have been emailing back and forth a bit and I can’t speak for him, but it appears as though all orders are executing properly on my end.

Quick question, on the stop loss and limit inputs, if these were left to 0 would that mean that no stop loss or limit would be entered?