Tying Entry-Exit and SetProfitTarget, SetStopLoss

Questions about MultiCharts and user contributed studies.
Luto
Posts: 9
Joined: 18 May 2022
Has thanked: 3 times

Tying Entry-Exit and SetProfitTarget, SetStopLoss

Postby Luto » 16 Aug 2022

Hi Everyone,

How do the built in orders handle orders that are tied. Are they Global?
Is there any way, in the engine, to tie the built in commands to the entry?

Code: Select all

If High[1] < High[0] then Buy ("Entry1") next bar 1 share at Market; If High[2] < High[0] then buy ("Entry2") next bar 2 shares at Market.; If High > High[2] + 10 then Sell next bar 1 share from entry ("Entry1") at market; if High > High[3] + 5 then Sell next bat 2 share from entry (Entry2") at market; SetProfitTarget (20); SetStopLoss (10);
As a work around I can create a conditional exits and just tie them to the entries.
Any comments are welcome
Thanks!

User avatar
Kate MultiCharts
Posts: 575
Joined: 21 Oct 2020
Has thanked: 7 times
Been thanked: 144 times

Re: Tying Entry-Exit and SetProfitTarget, SetStopLoss

Postby Kate MultiCharts » 22 Aug 2022

Hi Luto,

All the built-in orders in MultiCharts work in one of two ways:
  • SetStopPosition (by default) applies exit orders to a position, and the whole position is closed with one order.
  • SetStopContract applies an exit order to each entry order, calculating the price for each exit based on entry order execution price. So, a specific entry is closed, not the entire position.


Return to “MultiCharts”