GEMFOREX Signal Provider EA Manual

In order to register EA to GEMFOREX EA service, it is necessary to insert the code into EA according to this manual. This is a necessary content to protect the signal provider's EA and payment of reward, please be sure to comply.

Step1About coding of account binding

GEMFOREX automatically creates a code that operates only for the user's account number when the user downloads the EA registered by the signal provider. For that, it is necessary for the signal provider to write the following code in the mq4 file to be registered.

① Definition of Account Number

Please define account number. To define account number

int Accountnumber = %Accountnumber%;

(Please use copy & paste without adding line breaks)

② From intstart() to before the ordersend description part

From intstart() between ordersend,

if(IsDemo()==false){if(AccountNumber()!=Accountnumber){Alert("Usererror!CannotTrading.");return(0);}}

(Please use copy and paste without adding line breaks)

【When writing inside void onTick】

if(IsDemo()==false){if(AccountNumber()!=Accountnumber){Alert("Usererror!CannotTrading.");return;}}

(Please use copy and paste without adding line breaks)

With this coding, any DemoID will work in the Demo account, but in the real account, it will be the bounded up code of the ID holder who downloaded. Also, if a third party other than the downloader's ID applies this EA to the chart, the following error will appear

* If you compile after doing the code change, the following error will occur, but there is no problem in operation regarding this part.

This concludes the coding part of account binding.

Step2Coding for fee calculation

GEMFOREX uses comment function at the time of contract to discriminate and calculate fee when a user trades the EA provided by a signal provider. Therefore, we request the following coding.

① Comment description in the OrderSend function

In the order portion, comment description in the OrderSend function,

Please insert character string,

APP-%app_id%-USR-%member_id%-GEM-trade

Be sure to insert this string in all comments in the OrderSend function.

if(short_entry) (OrderSend(Symbol(),OP_SELL,Lots,Bid,50,0,0,"APP-%app_id%-USR-%member_id%-GEM-trade",MagicNumber,0,Red);)
if(long_entry) (OrderSend(Symbol(),OP_BUY,Lots,Ask,50,0,0,"APP-%app_id%-USR-%member_id%-GEM-trade",MagicNumber,0,Blue);)

Also, please avoid using the character string OrderSend other than the function of MQL4. (Avoid function names such as LongOrderSend () when creating other functions.)

※Attention (error message)

When registering EA, you can register EA from the signal provider's management screen, but when uploading registered EA, the account binding code and the comment part of OrderSend () is checked. If the description in the uploaded file does not contain the code to describe in this file and the code to describe in ordersend comment, the following error will be displayed when registering EA after uploading

There is a specification that it cannot be uploaded unless the number of functions of OrderSend () and the number of the comment field insertion part (APP-% app_id% - USR -% member_id% - GEM - trade) are the same. If an error occurs, please confirm the code once again, check this point.
(Even if you are using the character string OrderSend in other parts, such as your own function, that number will also be counted)

Please note the above points even if you are inserting comments using variables when creating an EA.

If an error occurs, a number is displayed at the end. The following are error contents, please check again.

  1. 「%Accountnumber%」の定義部分
  2. 「if(IsDemo()==false){if(....)}」の記述部分
  3. 「APP-%app_id%-.. とOrderSend」の記述回数不一致

Step3About Magic number

Since GEMFOREX allow users to use multiple EA, it is necessary to have specifications that allow you to check and change the magic number. Please set the magic number to extern shape as below and set it.

/*----- extern -----*/

extern int MagicNumber = 20100731001;
extern double Lots = 0.1;

▼ Check items of EA registration completion

If EA registration is successfully completed, it will be reflected on the site after examination and approval by our company. We will notify you, so after confirming the reflection, we are sorry to trouble you, but please do the test whether the EA is successfully registered.

【About the test】

In case it is difficult to make a deposit to a real account for the purpose of conducting a test, we can also respond with a demo account for testing, so if you wish, please contact us and we will guide you to support (Please specify, subject: "Request for Signal Provider demo account").

Please be sure to confirm yourself as the signal provider, whether the EA download is supposed to perform the expected operation.

We will not assume any responsibility when the user uses the downloaded EA and malfunction has occurred by any chance. Please be sure to perform sufficient operation check of the EA download.

If by any chance download is not possible, please do not hesitate to contact us below.

Contact Us
support@gforex.asia

▼ How to check the comment part

There is another point we would like you to check. This is an important part for reward confirmation, so please be sure to check.

If you insert the part of the comment field (APP-% app_id% - US -%% member_id% - GEM - trade) of the registered EA, it will be automatically replaced with the signal provider's control number when uploading.

We will manage reward with that control number. It is necessary to confirm that it is converted to the control number correctly. Please use the EA you downloaded and actually check it on MT 4.

1. Open a terminal window and select the Transactions tab.

2. If the comment field is not displayed when in default state, it should be displayed. Please right-click on the order column currently on hold and enable check of the "comment" from the display item.

3. The comment column will be added to the right end of the order list, so you can confirm. If it is converted to the following character string, it is reflected normally in the control number. Confirmation is completed.

If it is displayed according to the following inserted character string (APP-% app_id% - USR -% member_id% - GEM - trade), it is possible there is an error on the system, we are sorry to trouble you, but please notify us by e-mail.

Contact Us
support@gforex.asia

Points to note about the countdown method

"If Done ~" is not available.
The EA should be created without using the above code.

About symbol names

Normally, the symbol name is "currency pair" such as "USDJPY", but GEMFOREX uses the following symbol names, so careful attention is required in creation of EA.

Real account → USDJPYfx
No demo account is given.

That would be all.

If you have any questions, please feel free to contact our support.

GEMFOREX support
support@gforex.asia