![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Thanks the New_Bar code works.
It takes apox. 4-6 seconds into the new bar
before it detects a new bar.
I'm beginning to understand some of the flow in coding an EA.
I still have some bugs in my coding to work out though.
My next fn project is dynamic trailling stop.
Any suggestions?
My next fn project is dynamic trailling stop.
Any suggestions?
Sounds like you are making progress :-)
Lots of trailing SL stuff on here, you can use Google to search this site specifically, e.g. http://crum.be/trailsl
Thanks again
Could you help me with this code
if statement
{
if statement
{
while(true) // what is it using for true
{
if statement
{
if statement
Thanks again
Could you help me with this code
Yep, please try to use SRC for code it makes it easier to read . .
It could just as easily use . . .
Sorry I'm looking at a paper copy of a script.
I'm considering using if statements of conditions to OrderModify my stoploss for a dynamic trailing stop.
Will this produce any unforseen problems.
Scatch that last question i thought there was a trailingstop in OrderModify().
Thanks there is alot to look through.
There are some good custom indicators out there.
One of the ideas for an EA is to use an indicator to auto Buy sell.
I'm reading that i'm to use the #include directive.
#include <indicator name .mqh> header name.
Does this mean that the global variables of that indicator
with the assigned values are available on my EA ?
Or is it #import " indicator name.ex4"
Use of Indicators in an EA is usually via iCustom. You can pass variables to the indicator (that are specified in the Indicator code as extern) and you can get the Indicators buffers by return.
#include is used to bring additional files into your EA, #import allows you to bring in a specific function from an external file . . . I don't have much experience of using either.
https://docs.mql4.com/basis/preprosessor