[ARCHIVE] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 3. - page 73

 
I mean, I already had a profitable strategy, I've been trading for a while now... I just finished the Expert Advisor on it now.
 
vovan-gogan:
I mean, I already had a profitable strategy, I've been trading for a while now... I just finished the Expert Advisor on it now.
Then go to pay.ru immediately
 
IgorM:
Then it's urgent to pay.ru.

Would you say this is a good result for a robot on a 7 year period? I just don't know the capabilities of EAs yet, so I'm very interested
 
vovan-gogan:

Can you say it's a good result for a robot on a 7 year period? I just don't know the capabilities of EAs yet, so I'm very interested in it.

No, that's bullshit.

I would rather sell it on pay.ru and not bother.

 
sergeev:

No, that's bullshit.

I'd rather sell to pay.ru and not have to suffer.


If it's bullshit, who's going to buy it?
 
vovan-gogan:

If it's bullshit, who's gonna buy it?

Yeah, well, there's always a sucker.

the public's gonna eat it up.

 
sergeev:

Well, of course. There's always a sucker.

As they say, the public will eat it up.


I am not here to scam suckers, thank you of course. I will keep it for a while, gain some experience in programming, and then I will fully implement my strategy in my trading robot. Then, hopefully, it will be "no bullshit".
 
vovan-gogan:

You should at least post a report from the tester. People might stop bitching then. You really can't tell anything from the graph.

There's no point in changing the lot to a permanent one.

And this phrase is confusing...

 

Hi all!

guys, need some help!!! )))

my code does not work! help me fix it please)))

::: If price moves in the opposite direction, when it reaches -15/-20 p a pending order is placed to capture one more order when price comes back

void otlogka () {

int a, order, k=OrdersTotal();

for (a=k-1; a>=0; a--) {

if (OrderSelect(a, SELECT_BY_POS, MODE_TRADES)) {

if (OrderType()==OP_BUY) {

if (OrderProfit()+OrderCommission()+OrderSwap()<0) {

order=OrderSend(Symbol(),OP_SELLSTOP,Lot,NormalizeDouble(Ask,Digits)+15*Point,1,0,TP, "Otlogka",MagicNumber,5,0);

}}}}

if (OrderSelect(a, SELECT_BY_POS, MODE_TRADES)) {

if (OrderType()==OP_SELL){

if (OrderProfit()+OrderCommission()+OrderSwap()<0) {

order=OrderSend(Symbol(),OP_BUYSTOP,Lot,NormalizeDouble(Ask,Digits)-15*Point,1,0,TP, "Otlogka",MagicNumber,5,0);

}}}}

Thanks in advance!!!

Positive mood

Have a nice trade!!!

 

Where again more for less is confused, I give up.



665
grell 12.08.2011 15:03
There is a permanent error 129. Help me find the error.
static string sy[10]={"EURUSD","EURGBP","EURCHF","EURJPY","GBPUSD","USDCHF","USDJPY","GBPCHF","GBPJPY","CHFJPY"};
int init()
  {
   return(0);
  }
int deinit()
  {
   return(0);
  }
int start()
  {
    for(int i=0;i<10;i++)
      {
      if(exist(i)==1&&signal(i)==-1)close(i);
      if(exist(i)==-1&&signal(i)==1)close(i);
      if(exist(i)==0&&signal(i)==1)open(i,1);
      if(exist(i)==0&&signal(i)==-1)open(i,-1);  
      }  
   return(0);
  }
int exist(int symb)
  {
  for(int i=OrdersTotal()-1;i>=0;i--)
    {
    OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
    if(OrderSymbol()==sy[symb]&&OrderType()==OP_BUY)return(1);
    if(OrderSymbol()==sy[symb]&&OrderType()==OP_SELL)return(-1);
    }
  return(0);
  }
void close(int symb)
  {
  double ask=NormalizeDouble(MarketInfo(sy[symb],MODE_ASK),MarketInfo(sy[symb],MODE_DIGITS));
  double bid=NormalizeDouble(MarketInfo(sy[symb],MODE_BID),MarketInfo(sy[symb],MODE_DIGITS));
  for(int i=OrdersTotal()-1;i>=0;i--)
    {
    OrderSelect(i,SELECT_BY_POS,MODE_TRADES);
    if(OrderSymbol()==sy[symb]&&OrderType()==OP_BUY)OrderClose(OrderTicket(),OrderLots(),bid,3,Red);
    if(OrderSymbol()==sy[symb]&&OrderType()==OP_SELL)OrderClose(OrderTicket(),OrderLots(),ask,3,Red);
    }
  }
void open(int symb,int dir)
  {
  Alert(sy[symb],dir);
  double ask=NormalizeDouble(MarketInfo(sy[symb],MODE_ASK),MarketInfo(sy[symb],MODE_DIGITS));
  double bid=NormalizeDouble(MarketInfo(sy[symb],MODE_BID),MarketInfo(sy[symb],MODE_DIGITS));
  if(dir==1)
    {
    double tp=NormalizeDouble(ask+20*MarketInfo(sy[symb],MODE_POINT),MarketInfo(sy[symb],MODE_DIGITS));
    double sl=NormalizeDouble(iLow(sy[symb],1440,1)-ask+bid,MarketInfo(sy[symb],MODE_DIGITS));
    int res=OrderSend(sy[symb],OP_BUY,0.01,ask,5,sl,tp,"",54,Red);
    }
  if(dir==-1)
    {
    tp=NormalizeDouble(bid-20*MarketInfo(sy[symb],MODE_POINT),MarketInfo(sy[symb],MODE_DIGITS));
    sl=NormalizeDouble(iHigh(sy[symb],1440,1)+ask-bid,MarketInfo(sy[symb],MODE_DIGITS));
    res=OrderSend(sy[symb],OP_SELL,0.01,bid,5,sl,tp,"",54,Red);
    }
    int err=GetLastError();
    Alert("Ordersend_Number",res,err);
  }