Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 6. - page 719

 
evillive:

you can go like this:

Thank you!
 
AlexeyVik:

Or like this.

Bars still works.
Thank you!
 

Hello! Can you please advise how to solve the problem with the EA. The old demo I was testing my thoughts on is no longer supported, I dragged the EA to the new one, but it doesn't want to work here. When compiling, errors "_Point" - variable alreadydefined and "_Digits"- variable alreadydefined...

#include <stderror.mqh>

#include <stdlib.mqh>

 

extern int TP=0;              

extern int TS=80;            

extern int StepTS=20;  

extern int SL=0;              

extern double Lot=1;   

extern int Slip=0;            

extern int Magic=2013;

// служебные переменные

int Ticket[1000];

int err;

 

double FreezLvl, StopLvl, Spread, OpenLvl, Pnt, _Point, _Digits,  _Bid, _Ask, _Open, _Close;

datetime LastBarTrade;

//------------------------------------------------------------------ init

int init() { return(0); }

//------------------------------------------------------------------ deinit

int deinit() { return(0); }

//------------------------------------------------------------------ start

int start()

{

                if (!IsTradeAllowed() || IsTradeContextBusy() || !IsConnected()) return;

                string smb=Symbol();

                int tf=Period();

                double op, tp, sl;            

                int ticket;

                bool bSignal, sSignal, bcSignal, scSignal, b;           
 
karwin:

Hello! Please advise how to solve the problem with the EA. The old demo, on which I tested my thoughts, is no longer supported, I dragged the EA to the new one, but it doesn't want to work here. When compiling, errors "_Point" - variable alreadydefined and "_Digits"- variable alreadydefined...

Replace_Point, _Digits for example with dPoint, dDigits,
 
Vinin:
Replace_Point, _Digits for example with dPoint, dDigits,
Thanks for the tip! Everything works)).
 
Please advise a medium-quality and affordable VPS for 2Mt4, I don't want my EA to work inadequately because of it.
 
Mitruha:
I just don't know how to use them, I just don't feel like I'm not working with them.

If the account is opened at Roboforex, it is real and the money from 300 quid, the vps on their server is free for you.

I have no comment on others, I've never used them.

 

Hello!

Could you please tell me how to add a Heiken Ashi indicator value to the program, what function should I use?

 
Zeta:

Hello!

Could you please tell me how to add a Heiken Ashi indicator value to the program, what function to use?

iCustom(Symbol(),Period(),"Heiken Ashi",clBearShadow,clBoolShadow,clBearBody,clBoolBody,buffer,bar);

Where buffer - the value of the required buffer (0 - shadow of a bearish candle, 1 - shadow of a bullish candle, 2 - body of a bearish candle, 3 - body of a bullish candle),

bar - number of the needed bar (0 - current bar)

clBearShadow - colour of bear candlestick shadow, clBoolShadow - colour of bullish candlestick shadow, clBearBody - colour of bear candlestick body, clBoolBody - colour of bullish candlestick body.

You can use default values, then:

iCustom(Symbol(),Period(),"Heiken Ashi",buffer,bar);
 
artmedia70:

where buffer is the value of the required buffer (0 - bearish candlestick shadow, 1 - bullish candlestick shadow, 2 - bearish candlestick body, 3 - bullish candlestick body),

bar - number of the needed bar (0 - current bar)

clBearShadow - colour of bear candlestick shadow, clBoolShadow - colour of bullish candlestick shadow, clBearBody - colour of bear candlestick body, clBoolBody - colour of bullish candlestick body.

You can use default values, then:

Thanks!!!!!