EA Guide

This guide is to explain the different components of the PineConnector Expert Advisor.

Please refer to the Syntax Guide and the Alerts Guide
in conjunction with this EA Guide.


Syntax Guide →   Alerts Guide →


pineconnector mt5 ea

PineConnector MT5 EA Control Panel (default settings)


 

Login
Parameter
Remarks
License ID
  • Your License ID is the long number string found in the intranet.
Risk Settings
Parameter
Remarks
Maximum Open Positions
  • Define the maximum number of open positions
  • Use value "0" to not limit the open position count
Safety Stop Basis
  • Account Balance
  • Account Equity 
    • Account equity is your Account Balance + Total Floating Profit from all open positions
Safety Stop Action
  • Level 1 – Mobile Notification Only
  • Level 2 – Notify, and Halt EA Only
    • You will be notified via mobile notification (if set up) and via a popup on your MetaTrader
    • PineConnector EA will be halted – you may check the status on the attached chart
      • Label should read: "EA Status: EA HALTED"
  • Level 3 – Notify, Halt EA, and Close All Open Trades (Positions and Orders)
    • As per Level 2, and
    • All open positions (buy and sell) will be closed, and orders (buy limit, sell limit, buy stop and sell stop) will be cancelled
Safety Stop Value
  • Define the trigger value in terms of Balance or Equity (based on your "Safety Stop Basis" option) for the Safety Stop
    • Assume Safety Stop of "50" set. When your account Balance or Equity hits or goes below $50, the safety stop will trigger. The action taken will be either of the 3 Safety Stop Levels indicated above
  • Value used should be lower than the current Balance/Equity
  • Use value "0" to disable Safety Stop entirely
Reactivation Value
  • Define the automatic reactivation value in terms of Balance or Equity (based on your "Safety Stop Basis" option)
    • Continuing from the Safety Stop example, if set Reactivation Value of "55", once your account Balance or Equity goes above $55, the EA resume automatically.
  • Value used should be higher than the Safety Stop Value 
  • Use value "0" to disable Automatic Reactivation
Main EA Settings
Parameter
Remarks
Target type
  • Pips from current market price
  • Price indicated on your TradingView alerts message
  • Percentage from current market price
    • To have targets 1% from current market price, please use "sl=1" or "tp=1"
Volume type
  • Specified volume indicated on your TradingView alert message
    • Indicating "risk=1" will mean 1 volume/lot will be opened 
  • Percentage of account balance (ensure SL is specified)
    • Position size will be computed automatically based on the SL specified 
    • The amount that you will lose if your trade hits the specified SL
      • If you have an EURUSD trade with 15 pip SL with $1000, risk=1 with this Volume Type will mean that hitting the SL you will lose $10.
Pending Order Price
  • Pips from current market price
  • Price Specified from TradingView alert
  • Percentage from current market price
    • To have pending orders 1% from current market price, please use "price=1"
Pyramiding
    • Off - Either 1 Buy OR 1 Sell 
      • If you have either a buy or sell position open, all orders with the same symbol will not open
    • Off - Only 1 Buy AND 1 Sell 
      • If a trade of the same symbol and direction is already opened, all incoming alerts will not be opened
    • On
      • No restrictions imposed to new trades.
      • All new alerts will be opened
    • On - If symbol and direction in profit 
      • Conditional restriction imposed to new trades
      • New market and pending orders will only be opened if profit from all positions with the same symbol and direction is positive

    Examples

    Pyramiding = Off - Either 1 Buy OR 1 Sell

    1. Long EURUSD open. Incoming long EURUSD will not open
    2. Long EURUSD open. Incoming short EURUSD will not open

    Pyramiding = Off - Only 1 Buy AND 1 Sell

    1. Long EURUSD open, Incoming long EURUSD alert will not open
    2. Only Long EURUSD open. Incoming short EURUSD alert will open.
    3. Short EURUSD open, Incoming short GPBUSD will open normally since they are different symbols
    4. If one of your Pending Orders gets filled, all other Pending Orders in the same direction and symbol will be cancelled
      1. A buystop and a buylimit EURUSD pending orders in play. The buystop gets filled, the buylimit gets cancelled automatically.
    5. If you have an ongoing position, all pending orders in the same direction and with the same symbol will not be executed.
      1. A buy EURUSD position is open. All buystop and buylimit orders received will not be executed. 

    Pyramiding = On

    1. EURUSD open. Incoming EURUSD alert will be opened.
    2. Only EURUSD short open. Incoming GPBUSD short. GBPUSD will open normally. 

    Pyramiding = On - If symbol and direction in profit

    1. Sum of all long EURUSD floating profit is negative. Incoming buy, buystop and buylimit EURUSDs will not be open.
      1. Sample expert output:
    2. Sum of all long EURUSD floating profit is negative. Incoming long GBPUSD will open since symbol is different.
    3. Sum of all long EURUSD floating profit is negative. Incoming short EURUSD will open since direction is different.
    Hedging (Close on Reverse)
    • True (examples below) - opening a trade with the same symbol in the opposite direction will close the first trade and then open the second order.
    • False (examples below) - opening a trade with the same symbol in the opposite direction will NOT close the first trade.

     

    Examples

    Hedging = TRUE 

    1. Long EURUSD open. Incoming short EURUSD. Long EURUSD gets closed first. Short EURUSD opens.
    2. Long EURUSD open. Incoming short GBPUSD. Long EURUSD untouched. Short GBPUSD opens. 

    Hedging = FALSE 

    1. Long EURUSD open. Incoming short EURUSD. Nothing happens to the long EURUSD. Short EURUSD opens.

    *If you are looking to close the Long EURUSD and not open another position,
    the appropriate command will be "closelong" or "closeshort".

    Other EA Settings and Options
    Parameter
    Remarks
    EA and License Details
    • Display Full EA and License Details
    • Display only the License Expiry Date
    EA Magic Number
    • Default Magic Number of 76
    • Alternate Magic Number of 77
    • Alternate Magic Number of 78

     

    You may use different Magic Numbers to run different strategies on the same trading account. Please note that you will require multiple licenses to run, whereby you will have multiple License IDs as well.

    ​​​ 
    This means:
    • Strategy 1 -> runs on License ID 1 with magic number 76-> opens and closes based on alerts of strategy 1
    • Strategy 2 -> runs on License ID 2 with magic number 77-> opens and closes based on alerts of strategy 2

    For instance, on the same Trading Account. You would like to run a Moving Average Crossover Strategy on EURUSD 15 mins and 60 mins. The trade opens and closes will not be the same time despite being on the same symbol. 

    You will be required to use the Magic Number feature to run both strategies concurrently on the same Trading Account.
    Broker Set (MT5 EA only)
    • Broker Set A (Default)
    • Broker Set B (Unsupported Filling)
      • For those who face the Error 4756 Unsupported Filling Mode for Brokers such as ICMarkets
      • Compatible for clients who were using the "FM Mode" MT5 EAs

    Related Links

    2. Syntax