Hello freinds, I write an Expert which is running in EURCAD chart, and it uses the bid price of USDJPY?
I wrote the folowing lines:
RefreshRates();
double B_UJ = MarketInfo("USDJPY",MODE_BID);
And It still compute the veriable B_UJ as 0.0, WHY?
Can somebody help me?
Thankes
crossy,
Just check that and it's working fine on my mt4..
C
Your pairs may not be named exactly that, some micro accounts have a 'm' sufix, some others have '_fx' as the suffix
So look in Market Watch (button on MT tool bar) for any prefix or suffix and add this exactly in the call to MarketInfo
Good Luck
-BB-
C
Your pairs may not be named exactly that, some micro accounts have a 'm' sufix, some others have '_fx' as the suffix
So look in Market Watch (button on MT tool bar) for any prefix or suffix and add this exactly in the call to MarketInfo
Good Luck
-BB-
Thankes C, But i'm not at micro or something else, I'm at USDJPY - clean.
Hello robofx.org, I have the answer but it is still a problem.
As I run the EA on LIVE chart (also with demo) you get it right, but as you
do BACKTEST it is still ZERO. Can anybody help?
The tester is taking it as a multi-currency ea and they cannot be tested in the back tester. Hopefully muti-currency testing will be available in MT5
Keith
Hello robofx.org, I have the answer but it is still a problem.
As I run the EA on LIVE chart (also with demo) you get it right, but as you
do BACKTEST it is still ZERO. Can anybody help?
You are quite right, crossy. Made a backtest and result is 0 as you said. Strange.. suppose problem is in backtester.
Hello freinds, I write an Expert which is running in EURCAD chart, and it uses the bid price of USDJPY?
I wrote the folowing lines:
RefreshRates();
double B_UJ = MarketInfo("USDJPY",MODE_BID);
And It still compute the veriable B_UJ as 0.0, WHY?
Make sure USDJPY is presented in Market Watch list.
BTW RefreshRates() has nothing to do with MarketInfo().
Hello robofx.org, I have the answer but it is still a problem.
As I run the EA on LIVE chart (also with demo) you get it right, but as you
do BACKTEST it is still ZERO. Can anybody help?
Hello
If i get it right you need to be connected because even though its working with historical data, the backtest needs access to updated marketinfo data
I have same problem using mini lots
The orders are rejected when not connected. When it works using normal lots and not being connected
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello freinds, I write an Expert which is running in EURCAD chart, and it uses the bid price of USDJPY?
I wrote the folowing lines:
RefreshRates();
double B_UJ = MarketInfo("USDJPY",MODE_BID);
And It still compute the veriable B_UJ as 0.0, WHY?
Can somebody help me?
Thankes