General Settings

<<GENERAL SETTING>>

<EA status>

The "EA status" setting

__Running mode: Scan & trade (trade if any new signal comes)

Running mode "Scan & trade (if any new signal comes)"

The default value is “Scan & trade”, which means the EA will continually scan to detect a new signal text content in the signal text source file every second and trade if the signal text content meets some text conditions that trigger trading events.

You should set up these conditions by inputting text values in “Texts TRIGGER” & “Texts BLOCK” parameters in events’ settings. You will understand more about these parameters at the below parts.

__Running mode: Analyze signal text (show word & number location values)

Running mode "Analyze signal text (show word & number location values)"

Sometimes, you input wrong number location values for the open price, stop loss, and take profit(s) that cause the problems of the EA can't open a new order (for example). This function will help you get the number location values correctly.

If you choose a value “Analyze signal text”, then click the “OK” button to run the EA, the EA will read the txt source file and pop-up an “Alert” window, showing a signal text content with word location values of all words & number location values of all numbers in the signal text (see the below images).

An “Alert” window shows a signal text content with word location values and number location values.

If you don't see the "Number Locations" part, use a scroll bar on the right to scroll down to see the number location values in the signal content.

Scroll down the right bar to see the number location values (if the EA can detect many number values).

The signal text content showed in “Alert” window is the text content under EA’s perspective after a/some text(s) is replaced or removed by a “Re-write signal text” function (you will learn more about this function in  below parts). The EA will read the modified signal text content, not the original signal text content.

The number location values showing in “Alert” window are the position values of the numbers that the EA can detect in the signal text. 

Remember that the EA only can detect a/the number(s) if there are a space before the number and a space behind the number. Otherwise, the numbers will be treated as texts (not numbers).

For example: "1.22330" will be treated as a number with a value as “1.22330” but "@1.22330" will be treated as a text with a value as “@1.22330”.

__Debug mode (show an alert window)

The default value is “true”, which means the EA will print texts in the MT4 “Experts” tab & pop-up an “Alert” window to give all information about what it’s doing.

The EA prints text in the MT4 “Experts” tab
The EA shows an "Alert" window

You can read the texts in “Experts” tab and “Alert” window to know what the EA is doing. Click to read contents in every line (from the |||START||| line to the top line) to know what the EA is doing step by step.  This is an easy way to understand how the EA works and to find the bugs. Don't just ask me why the EA didn't trade without give me about these information. The EA will tell you all what he is doing and what he gets stuck.

I encourage you to keep the __Debug mode setting as “true” in the beginning of several months to understand how the EA work, to find your correct settings, and to debug.

If you set “false”, the EA will no longer print the texts in the “Experts” tab and not pop up the “Alert” window to give the information anymore. This setting value will help the EA run faster and even smoother. Only use this setting when you have the best set file.

__Signal text source file (*.txt file in folder \MQL4\Files\..): 

The "Signal text source file" value with a default setting.

The setting value is a full file name of the source txt file containing the signal text. 

This txt file must be located at data folder of metatrader 4 …MQL4\Files\… 

You can access this folder by clicking the menu “File” in your MT4 application, then click “Open Data Folder”. An explorer window will appear and you can access the folder …MQL4\Files\…

How to access the MT4 data folder “...MQL4\Files\...”

As default value of the "__Signal text source file" parameter is ”telegramsignaltext.txt” but you can change it to any filename you like. It means the EA will read the text content in the file ”telegramsignaltext.txt” for trading. Remember that this txt file must be located in the “Files” folder so that the EA can read and trade.

When the EA runs, it will check the existence of the file ”telegramsignaltext.txt” first. If the file doesn’t exist, the EA will create it. If the file already exists, the EA will read the txt file every second to detect new content from the file to trade.

When the file’s content is changed (the new signal comes), the EA will analyze the text content and trade if any of the text conditions is/are met.

<Signal structure>

"Signal structure" setting

__Signal does NOT provide Symbol name(s): The default value is "false". The EA will not trade if the signal text doesn't provide a symbol name. Set this value as "true" in a case that the signal provide signal for just 1 symbol, such as GOLD. In this case, you should input the symbol name in "Only trade Symbols" setting.

__Signals provides Stop loss values as a Pip unit: The default value is “false”. Set it “true” if the signal provides the stop-loss price value in the pip unit.

__Signals provides Take profit values as a Pip unit: The default value is “false”. Set it “true” if the signal provides the take profit price value in the pip unit

Explain: Some signals provide values of Stop loss or/and Take profit in pip unit. See a below example signal:

BUY EURUSD
Entry price: 1.21555
Stop loss: 50 pips
Take profit: 75 pips

To trade this signal, we should set the value for these parameters as “true”, the EA will automatically calculate the price values for Stop loss and/or Take profit base on pip values.

<Powers of the EA>

"Powers of the EA" setting

__Allow the EA to open many orders having the SAME properties: The default value is “false”, which means the EA will not open more a new order having all properties the same as an open order’s properties (symbol, lot size, open price, stop loss & take profit values) – there is already an open order with the same properties.

If you set this parameter as “true”, the EA will still open a new order regardless of there is/are an/many open order(s) having the same properties.

__Allow the EA to open OPPOSITE orders with open orders: The default value is “true”, which means the EA can open new opposite orders (open a new buy/ buy limit/ buy stop order of a symbol if there is/are already a/ many open sell/ sell limit/ sell stop order(s) of this symbol, and vice versa). Set this value as “false” if you don’t want the EA to open a new order of a symbol if there is already any open opposite order of this symbol (for example: doesn’t open a new buy order of a symbol if there is/are already a/many open sell order(s) of this symbol).

__Allow the EA to manage orders which it did NOT open: The default value is “false”, which means the EA only manages orders that it has opened based on the order’s magic number value.

If you set this parameter as “true”, the EA will manage all open orders in the trading account including orders opening by other EAs or manual trading.

You will need this function when you have many EAs or/and you also trade manually, and you don't want these trading styles are conflict to each other.

<Change the Broker & Computer times to your Local time>

Image: Change to your Local time parameters

__Your local time (GMT) – Broker server time (GMT) =: Change the broker server time to your local time.

For example: If your local time GMT is +7 and your broker server time GMT is + 4, you should input the value “3” in this parameter. Because (+7) - (+4) = 3.

This function will be used in the “Pause Trading” function to help the EA pause & resume trading in your local time (default is in broker server time).

__Your local time (GMT) – MT4 computer time (GMT) =: Change the MT4 computer time to your local time.

For example: If your local time GMT is +1 and your MT4 computer time GMT is – 4, you should input the value “5” in this parameter. Because (+1) - (-4) = 5. 

This function will be used for parameter “At times (hh:mm;hh:mm;...)" in  “Auto Close All Orders” function when the EA will close all open orders in your local time (default is MT4 computer time).

“At times (hh:mm;hh:mm;...)" parameter in  “Auto Close All Orders” function

<Customize Pip unit> set private price per pip for each symbol

“Pip unit customize” parameters

By default, the EA will define the pip unit base on the number next to the last number. 

For example: If the broker shows the GBPUSD price as 1.26683, the last number is 3, the number next to the last number is 8, so the pip unit is 0.0001. See below table.

Price1.26683
Pip unit0.0001 

Default pip unit is 0.0001

Another example: If the broker shows the XAUUSD price as 1382.74, the last number is 4, the number next to the last number is 7, so the pip unit is 0.1. See below table.

Price1382.74
Pip unit   0.1 

Default pip unit is 0.1

Another example: Some broker shows the XAUUSD price as 1382.745, the last number is 5, the number next to the last number is 4, so the pip unit is 0.01. See below table.

Price1382.745
Pip unit   0.01 

Default pip unit is 0.01

In this case, you may want to define the XAUUSD pip value as 0.1, then you should input value for parameter __0.1 as "XAUUSD"

__10: Define some symbols having pip unit as 10. For example, if the broker shows the BTCUSD price as 23350.20, it means the default pip value is 0.1. However, if you input value here as “BTCUSD”, the EA will overwrite the default value and set the unit pip of BTCUSD as 10. Then the price change from 23350.20 to 23360.20 will be a +1 pip.

__1: Define some symbols having pip unit as 1. For example, if the broker shows the XAUUSD price as 1382.74, it means the default pip value is 0.1. However, if you input value here as “XAUUSD”, the EA will overwrite the default value and set the unit pip of XAUUSD as 1. Then the price change from 1382.74 to 1383.74 will be a +1 pip.

__0.1: Define some symbols having pip unit as 0.1. Similar above example.

__0.01: Define some symbols having pip unit as 0.01. Similar above example.

__0.001: Define some symbols having pip unit as 0.001. Similar above example.

__0.0001: Define some symbols having pip unit as 0.0001. Similar above example.