Re: New Portfolio Expert with Protections and a News Filter
> Question: is F3 the final solution? Or just a temporary workaround?
The expert should remove the trade hold at midnight if it runs properly.
I'll try to see how to make it more robust.
Create and Test Forex Strategies
You are not logged in. Please login or register.
Forex Software → Portfolio Expert → New Portfolio Expert with Protections and a News Filter
> Question: is F3 the final solution? Or just a temporary workaround?
The expert should remove the trade hold at midnight if it runs properly.
I'll try to see how to make it more robust.
did you guys have the same problem that ea does nothing in mt4 tester? i have to change in code
void OnTick(void)
{
if(ArraySize(Time) < requiredBars)
return;
if(!MQLInfoInteger(MQL_TESTER))
{
UpdateAccountProtection();
CheckAccountProtection();
to
void OnTick(void)
{
if(ArraySize(Time) < requiredBars)
return;
if(MQLInfoInteger(MQL_TESTER))
{
UpdateAccountProtection();
CheckAccountProtection();
than ea open trades.
@Popov there must be a bug in Position Calculation. Can someone check. When i make visual MQL Tester .
The Position calculation is wrong and it not show Profit
I check again. when i leave in settings all to 0 it is calculating positions wrong and not show Profit. When i use 10 positions than it shows profit and calculate good..So if we use Posit stats true only it is calculating wrong
i justed check code
in OnTick this line must be deleted and it worked.
if(MQLInfoInteger(MQL_TESTER))
{
UpdateAccountProtection();
CheckAccountProtection();
const datetime time = TimeCurrent();
if(time > lastStatsUpdate + 3)
{
lastStatsUpdate = time;
// if(Max_OpenPos > sigma || Max_OpenLots > sigma)
SetPosStats();
UpdateStats();
}
// if(Max_OpenPos > sigma || Max_OpenLots > sigma)
In in your behaviour cause u let us set PosStat ON/OFF it have to be
if(Pos_Stat)
SetPosStats();
I think ;-)
Daily Loss:
Now i checked why is when i set Daily Loss 1000. Than it show eg 3000 and activate to late? Normally it should close and suspend at 1001.
BTW: What the difference between MaxOpen Lots and Max Positiions?
There must be a BUG.
The globalVariables are not initialized @Popov
You have forgot to call the function in OnInit!
InitGlobalVariables();
<--
where is @Popov
Forex Software → Portfolio Expert → New Portfolio Expert with Protections and a News Filter
Powered by PunBB, supported by Informer Technologies, Inc.