• Overview
  • Reviews (1)
  • Comments (17)
  • What's new

Virtual Sl Tp and trailing Sl

This panel brings convenient functionality. It will make your manual or automated trading in the Meta Trader terminal more comfortable.


  1. This panel allows to hide the Stop Loss and Take Profit levels of your trades. The panel stores these levels in its memory. When the market price reached one of the levels, a trade is simply closed and terminal generates a message indicating that a virtual level was triggered. This feature can be disabled.
  2. there are 5 options for setting Stop Loss:
    • Classic SL - fixed Stop Loss (pips_SL parameter)
    • Trailing SL - when the distance from the current price to the trade opening price is greater than the value of the pips_TRSL parameter, Stop Loss is moved by pips_TRSL.
    • Breakeven - Trailing SL until the "break even" price - similar to the previous one, but the algorithm works up to the trade opening previous
    • Trailing SL "jumps" - when the position profit in pips is equal to the value of pips_TRSL_1, the Stop Loss level is set to the position opening price (to breakeven). If Stop Loss is at "breakeven" and the distance from the current price to the opening price becomes equal to pips_TRSL_2, the Stop Loss order is moved away from the opening price to fix the profit in pips equal to pips_TRSL_3. This Trailing Stop Loss method is very efficient, it has been tested on different strategies. The algorithm is shows on the screenshot below.
  3. It is possible to work with all trades on the symbol or with trades with the specified Magic (useful for working with an EA)
  4. It is possible to set Take Profit
  5. It is possible to draw the SL and TP levels as conventional lines on the chart
  6. It is also possible to set the main settings right on the panel
  7. Settings can be adjusted from the visual panel
  8. When using hidden levels, there is an option to add "live levels" for SL (which are greater than the virtual level by the specified number of points)


  1. invisible_money_management_inp - false - the Stop Loss and Take Profit levels are output to the market. True - the levels are virtual and you broker "cannot see" them
  2. need_live_sl_inp- true - if invisible_money_management_inp = true, SL levels are set to the market, located away from the virtual SL by live_sl_point_inp points.
  3. live_sl_point_inp - described above
  4. all_orders_or_by_magic: All_orders - work with all orders on this symbol. Only_by_magic - work with orders and specific magic, specified in the magic_number parameter
  5. magic_number - magic number (described above). If it is set to less than or equal to 0, then the EA automatically works with all magic numbers
  6. color_of_SL - color of the SL line when using virtual SL, TP.
  7. color_of_TP - color of the TP line when using virtual SL, TP.
  8. TP_point_inp - distance of the Take Profit level from the trade opening price (specified in point)
  9. need_TP_inp - use Take Profit.
  10. type_of_trailing_inp - type of trailing sl (types are described above)
  11. TRSL_point_inp; SL_point_inp; TRSL_1_point_inp; TRSL_2_point_inp; TRSL_3_point_inp - values for setting SL and trailing SL (in points)
  12. visual_panel_DRAW - draw the visual panel. Offset from the chart corner to the visual parameter is defined by the following parameters: visual_panel_X; visual_panel_Y
  13. ON_when_start_inp - enable working on startup (can be enabled after startup suing the visual panel)


If the virtual SL/TP levels are enabled and for some reason the connection between the terminal and broker is lost (connection interruption, broker not responding or something else), trades will not be closed when those levels are reached

Javier Angel Labandeira Garcia
Javier Angel Labandeira Garcia 2018.10.12 21:39 

I checked this EA only with parameter "Just SL" and TP, I don´t need other functions by now.

It works very well in my hedge account, manual or with an EA, for All orders or just for Magic number (1 or more magics openig Virtual_SL_EA in more graphs).

It has a good price and works, autor has been very helpful fixing some bug, and similar EAs that I checked were more expensive and had errors.

So, 5 stars for Virtual SL/TP is the correct.

The only missed thing is a full functional demo just for 1 symbol(CADJPY or other minor), so that we were able of checking its functions before buying it.

Version 5.0 2018.10.12
Fixed bugs
Version 4.0 2018.10.04
Fixed bugs
Version 3.0 2018.08.23
Fixed bugs
Version 2.0 2018.06.05
1 - now the EA is able to set the virtual SL and TP levels closer than the minimum distance allowed by the broker
2 - added the ON/OFF button to the visual panel