How to add a comment & change the color for the
7 replies
josecort_trader
6 years ago #118016
Hello
On Metatrader when a trade is closed it is written a comment on at the comment column in Account tab. After my EAs made by the SQ wizard close a trade, on the comment it is just said, for example, [sl] if the trade was closed by reaching the stop loss. Is it possible to add more info: EA’s name, Magicnumber, etc.?
On the other hand, I would like to ask how could I change the color for the EA info that appears on the chart. By default is white.
THANKS
tomas262
6 years ago #145313
Hello,
to add a text into MetaTrader4 journal use the Log to Journal function as show in the example attached
Also you can change label color as shown. Just doubleclick the label and use the right click to select label properties
You can also us WIzard to change the color for you by a custom action applied with code:
ObjectSet("line1", OBJPROP_COLOR, Red); // Sets EA name text color to red
josecort_trader
6 years ago #145314
josecort_trader
6 years ago #145315
Sorry tomas262
Where I have to add the custom action for setting a color by default? As it is shown on the attached picture?
THANKS
tomas262
6 years ago #145316
josecort_trader
6 years ago #145328
Zoki
5 years ago #235835
About adding the comment, I’m lost watching this source code.
Can you tell how to program it inside EA Wizard?
For instance, I made few versions of EA just for closing trades and attached them to few charts. How can I know which one closed particular trade without comment? So I would just add comment when trade is closed, to know which EA closed what.
Thank you!
Zoki
tomas262
5 years ago #235853
Hello,
you can add Log To Journal behind your closing function with parameter: “Trade close for: “+Symbol()
So you will see what symbol the EA closed a trade on
Viewing 7 replies - 1 through 7 (of 7 total)