I am just starting with MQL so the following could be a programming mistake but
I don't think so.
My first real EA involves setting BuyStops and Sellstops at channel boundaries.
Then on the first bar of each day, adjust the orders if the orders haven't converted
to actual Buy or Sells yet. Because the orders are modified each day, I want to
not show the arrows when the orders are modified. The rules for OrderModify arrow_color
say: "Arrow color for StopLoss/TakeProfit modifications in the chart. If the parameter
is missing or has CLR_NONE value, the arrows will not be shown in the chart."
As you can see, I've left off the color parameter (ignore the //line please).
if(OrderType()==OP_BUYSTOP && NewDay)
{
//OrderModify(OrderTicket(),ChannelUp,ChannelDown,0,0);
Print("Reset Buy stop to ",ChannelDown);
BuyActive = true; // only 1 at a time
}
if(OrderType()==OP_SELLSTOP && NewDay)
{
//OrderModify(OrderTicket(),ChannelDown,ChannelUp,0,0,Red);
OrderModify(OrderTicket(),ChannelDown,ChannelUp,0,0);
Print("Reset Sell stop to ",ChannelUp);
SellActive = true; // only 1 at a time
}
To make things stranger, when I hover over the charts I sometimes see two different
hover notes.
Both notes pertain to the 2nd arrow from the bottom on the left and are from the
same exact run. #2 Sell stop (2nd chart) is the correct comment.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
My first real EA involves setting BuyStops and Sellstops at channel boundaries. Then on the first bar of each day, adjust the orders if the orders haven't converted to actual Buy or Sells yet. Because the orders are modified each day, I want to not show the arrows when the orders are modified. The rules for OrderModify arrow_color say: "Arrow color for StopLoss/TakeProfit modifications in the chart. If the parameter is missing or has CLR_NONE value, the arrows will not be shown in the chart."
As you can see, I've left off the color parameter (ignore the //line please).
if(OrderType()==OP_BUYSTOP && NewDay) { //OrderModify(OrderTicket(),ChannelUp,ChannelDown,0,0); Print("Reset Buy stop to ",ChannelDown); BuyActive = true; // only 1 at a time } if(OrderType()==OP_SELLSTOP && NewDay) { //OrderModify(OrderTicket(),ChannelDown,ChannelUp,0,0,Red); OrderModify(OrderTicket(),ChannelDown,ChannelUp,0,0); Print("Reset Sell stop to ",ChannelUp); SellActive = true; // only 1 at a time }To make things stranger, when I hover over the charts I sometimes see two different hover notes.Both notes pertain to the 2nd arrow from the bottom on the left and are from the same exact run. #2 Sell stop (2nd chart) is the correct comment.
Here is the results page for further documentation.
1 2006.05.22 00:00 buy stop 1 0.10 1.2936 1.2618 0. 0000 0. 00 10000. 00
2 2006.05.22 00:00 sell stop 2 0.10 1.2618 1.2936 0. 0000 0. 00 10000. 00
3 2006.05.23 00:00 modify 1 0.10 1.3038 1.2678 0. 0000 0. 00 10000. 00
4 2006.05.23 00:00 modify 2 0.10 1.2678 1.3038 0. 0000 0. 00 10000. 00
5 2006.05.24 00:00 modify 1 0.10 1.2926 1.2636 0. 0000 0. 00 10000. 00
6 2006.05.24 00:00 modify 2 0.10 1.2636 1.2926 0. 0000 0. 00 10000. 00
7 2006.05.25 00:00 modify 1 0.10 1.2886 1.2627 0. 0000 0. 00 10000. 00
8 2006.05.25 00:00 modify 2 0.10 1.2627 1.2886 0. 0000 0. 00 10000. 00
9 2006.05.26 00:00 modify 1 0.10 1.2947 1.2707 0. 0000 0. 00 10000. 00
What am I missing here? First as regards making the arrows disappear and secondly regarding the Hover message.
Thanks in advance for any guidance.
Rollin
PS I am on build 205 and my screen resolution is 1280 x 1024 if that makes any difference.