Yes.trader689 » Sun Jul 16, 2017 5:11 pm wrote:hey Steve
do you have any open DD for those m1 PoS trades?
thanks, trader
Peaky on Steroids
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
There is a fault in the code that closes ALL trades on the platform regardless of their origin. This fault exists in both versions. Copy this over the top of void NuclearOption():

Code: Select all
void NuclearOption()
{
ForceTradeClosure= false;
if (OrdersTotal() == 0) return;
//Put all the order tickets into an array for our friends in the US
int Tickets[];
int as = 0;
for (int cc = OrdersTotal() - 1; cc >= 0; cc--)
{
if (!BetterOrderSelect(cc, SELECT_BY_POS, MODE_TRADES))
continue;
ArrayRange(Tickets, as + 1);
Tickets[as] = OrderTicket();
as++;
}//for (int cc = OrdersTotal() - 1; cc >= 0; cc--)
if (as == 0)
return;//Just in case
ArraySort(Tickets, WHOLE_ARRAY, 0, MODE_DESCEND);
bool result = false;
for (int pass = 0; pass <= 1; pass++)
{
if (OrdersTotal() == 0 || OpenTrades == 0)
break;
for (int cc = ArraySize(Tickets) - 1; cc >= 0; cc--)
{
if (!BetterOrderSelect(Tickets[cc], SELECT_BY_TICKET, MODE_TRADES) ) continue;
while(IsTradeContextBusy()) Sleep(100);
if (OrderType() < 2)
{
result = OrderClose(OrderTicket(), OrderLots(), OrderClosePrice(), 1000, CLR_NONE);
if (result)
{
Tickets[cc] = -1;
OpenTrades--;
}//(result)
if (!result) ForceTradeClosure= true;
}//if (OrderType() < 2)
if (pass == 1)
if (OrderType() > 1)
{
result = OrderDelete(OrderTicket(), clrNONE);
if (result)
{
Tickets[cc] = -1;
OpenTrades--;
}//(result)
if (!result) ForceTradeClosure= true;
}//if (OrderType() > 1)
}//for (int cc = ArraySize(Tickets) - 1; cc >= 0; cc--)
}//for (int pass = 0; pass <= 1; pass++)
}//End void NuclearOption
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
- Gertje
- Trader
- Posts: 1936
- Joined: Mon Dec 12, 2011 1:17 pm
- Location: Middle of the Netherlands
Peaky on Steroids
I started PoS last week on the 4 timeframes that were in the OOTB settings.
Just before the weekend, I saw the M5 and M15 gaining a lot, but also building huge DD so I decided to go forward with only the H1 and H4 timeframes.
Attached is the beaty of PoS showing, a week ago a trade on the H1 opened, and 2 recovery trades opened since.
Today the 3 trades closed with a healthy profit, and PoS opened the same trade again, let's see if price will act like it is supposed to.
Just before the weekend, I saw the M5 and M15 gaining a lot, but also building huge DD so I decided to go forward with only the H1 and H4 timeframes.
Attached is the beaty of PoS showing, a week ago a trade on the H1 opened, and 2 recovery trades opened since.
Today the 3 trades closed with a healthy profit, and PoS opened the same trade again, let's see if price will act like it is supposed to.
You do not have the required permissions to view the files attached to this post.
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
The nuclear option code is still wrong and needs replacing with this:

Code: Select all
void NuclearOption()
{
ForceTradeClosure= false;
if (OrdersTotal() == 0) return;
//Put all the order tickets into an array for our friends in the US
int Tickets[];
int as = 0;
for (int cc = OrdersTotal() - 1; cc >= 0; cc--)
{
if (!BetterOrderSelect(cc, SELECT_BY_POS, MODE_TRADES))
continue;
ArrayResize(Tickets, as + 1);
Tickets[as] = OrderTicket();
as++;
}//for (int cc = OrdersTotal() - 1; cc >= 0; cc--)
if (as == 0)
return;//Just in case
ArraySort(Tickets, WHOLE_ARRAY, 0, MODE_DESCEND);
for (int cc = ArraySize(Tickets) - 1; cc >= 0; cc--)
{
if (!BetterOrderSelect(Tickets[cc], SELECT_BY_TICKET, MODE_TRADES) ) continue;
while(IsTradeContextBusy()) Sleep(100);
bool result = false;
if (OrderType() < 2)
{
result = OrderClose(OrderTicket(), OrderLots(), OrderClosePrice(), 1000, CLR_NONE);
if (result)
{
Tickets[cc] = -1;
OpenTrades--;
}//(result)
if (!result) ForceTradeClosure= true;
}//if (OrderType() < 2)
if (OrderType() > 1)
{
result = OrderDelete(OrderTicket(), clrNONE);
if (result)
{
Tickets[cc] = -1;
OpenTrades--;
}//(result)
if (!result) ForceTradeClosure= true;
}//if (OrderType() > 1)
}//for (int cc = ArraySize(Tickets) - 1; cc >= 0; cc--)
}//End void NuclearOption
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
The power of a combo of patience and filling in the gaps when the market is being uncooperative:

You do not have the required permissions to view the files attached to this post.
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
-
acostafulano
- Trader
- Posts: 243
- Joined: Tue Dec 06, 2011 3:40 pm
Peaky on Steroids
Hi Steve, just made the switch from v1j to v1j (Untested functions) and got a zero divide error.
I hope this doesn't get me grilled, But where should I look for this error? Looked around all the peaky subforums and didn't find any mention to this
Diego
I hope this doesn't get me grilled, But where should I look for this error? Looked around all the peaky subforums and didn't find any mention to this
Diego
- Vokin
- Trader
- Posts: 51
- Joined: Tue Dec 06, 2011 4:31 pm
Peaky on Steroids
Ooops - still close ALL...SteveHopwood » Tue Jul 18, 2017 6:41 pm wrote:The nuclear option code is still wrong and needs replacing with this:
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
This happens when one of the two variables in a division has a zero value. For example:acostafulano » Wed Jul 19, 2017 6:10 am wrote:Hi Steve, just made the switch from v1j to v1j (Untested functions) and got a zero divide error.
I hope this doesn't get me grilled, But where should I look for this error? Looked around all the peaky subforums and didn't find any mention to this
Diego
x = 10
y = 0
x / y will throw up the zero divide error.
Look in your platform's Experts tab. EA errors are clearly marked with a red circle and white dash in the middle - a 'No Entry' road sign here in the UK. This gives the line and character number of the error and will help me track it down. It has not happened on my platform, so I do not know where to look.
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
-
acostafulano
- Trader
- Posts: 243
- Joined: Tue Dec 06, 2011 3:40 pm
Peaky on Steroids
Hello Steve,
This is the error I got, and the setfile I got it with. As noted before, this was running perfectly under v1j right before getting this error, and the setfile was the same settings just updated to the new parameters available in the untested version.
This is the error I got, and the setfile I got it with. As noted before, this was running perfectly under v1j right before getting this error, and the setfile was the same settings just updated to the new parameters available in the untested version.
You do not have the required permissions to view the files attached to this post.
- SteveHopwood
- Owner
- Posts: 9904
- Joined: Tue Nov 15, 2011 8:43 am
- Location: Misterton - an insignificant village in England. Very pleasant to live in.
Peaky on Steroids
Whom is your broker?acostafulano » Wed Jul 19, 2017 5:59 pm wrote:Hello Steve,
This is the error I got, and the setfile I got it with.
As noted before, this was running perfectly under v1j right before getting this error, and the setfile was the same settings just updated to the new parameters available in the untested version.
Read the effing manual, ok?
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.
Afterprime is the official SHF broker. Read about them at https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?p=175790#p175790.
I still suffer from OCCD. Good thing, really.
Anyone here feeling generous? My paypal account is always in the market for a tiny donation. pianodoodler@hotmail.com is the account.
To see The Weekly Roundup of stuff you guys might have missed Click here
My special thanks to Thomas (tomele) for all the incredible work he does here.