Buy + Sell Every New Candlestick EA - page 2

 
pipspider:
How the trades are closed? by TP/SL or is there a another method ?

You can try that.

Can be either TP, SL and or Trailingstop(s) and or New candle arrival and or new day and or new week and or new month and or.

It seems that there is enough for you to try.

 
Marco vd Heijden:

The people that already have their conclusions as to why something can work or can not work, on forehand, those are the most dangerous people to communicate with.

In this world the only real feedback results are gathered from testing and trying things.

You could consider that trial and error, but with a definite direction in search for a final working solution like:

'I do this, so that.....'  

WOW. Nice words Man.

Thanks a lot

 
pipspider:
How the trades are closed? by TP/SL or is there another method ?

Not much interested on SL values. Only TP or TrailingStops important for now.

Please make it for me if you can

Thanks man

 
Marco vd Heijden:

You can try that.

Can be either TP, SL and or Trailingstop(s) and or New candle arrival and or new day and or new week and or new month and or.

It seems that there is enough for you to try.

Yeeeeeeees exactly what i think.

Cheers Man. I think we are on a same page

 
MT4 Trading:

Yeeeeeeees exactly what i think.

Cheers Man. I think we are on a same page

I don't think we are on the same page because of this:

MT4 Trading:

Please make it for me if you can

If you really want to succeed, you design it, you build it and you test it.

This way you are assured of gaining the necessary knowledge.

As you might know, wisdom is not something that is given, or bought, it is something that is attained.

 
#include <Trade\Trade.mqh>
CTrade Trade;

void OnInit()
{
     Trade.SetTypeFillingBySymbol(_Symbol);
     Trade.SetExpertMagicNumber(12345);
     Trade.SetMarginMode();
     Trade.SetDeviationInPoints(5);
     Trade.LogLevel(LOG_LEVEL_ERRORS);
}
void OnTick()
{
     static datetime timeBar = 0;
     datetime tBar[];
     CopyTime(_Symbol, 0, 0, 1, tBar);
     if(timeBar == tBar[0])
          return;
     timeBar = tBar[0];
     
     if( Trade.Buy( 0.1, _Symbol, SymbolInfoDouble(_Symbol, SYMBOL_ASK)) )
          bool r = Trade.Sell( 0.1, _Symbol, SymbolInfoDouble(_Symbol, SYMBOL_BID));
}
 
 
Marco vd Heijden:

I don't think we are on the same page because of this:

If you really want to succeed, you design it, you build it and you test it.

This way you are assured of gaining the necessary knowledge.

As you might know, wisdom is not something that is given, or bought, it is something that is attained.

Yes

 
Konstantin Nikitin:
 

Wow thanks a lot my friend. Please make it to work on MT4 if you can.


Thanks a lot man. You are a star


Cheers

 

See @Konstantin Nikitin made it, and then there is the demand for more.... (without even looking/trying the provided code)

This is a trend.

We would rather have @Konstantin Nikitin provide more code (for free) then to install MT5 and use his code.

Wisdom is attained, not given.

No matter how much code @Konstantin Nikitin provides to @MT4 Trading , @MT4 Trading is going to fail until he puts in the hard work himself.

If he ever will.... 

 
Konstantin Nikitin:
 
#include <Trade/Trade.mqh>

Also this line. Please also attach it