StopLoss and TakeProfit executed on Server?

Created at 11 Aug 2017, 10:12
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
AN

andi21

Joined 14.12.2016

StopLoss and TakeProfit executed on Server?
11 Aug 2017, 10:12


Hello Spotware,

i have just two short questions:

1. Here /forum/cbot-support/11767#5 you have said:

Stop Loss and Take Profit are executed on the server, therefore it does not matter whether your cBot is running or not.

 I thought StopLoss and TakeProfit are only executed clientside, so if somebody is running a bot / open positions and cAlgo has been closed, StopLoss and TakeProfit are not executed / considered and the "server-executing"-SL and -TP are only a separate / unique option in cTrader. Is that a new feature? So to be sure: if i have open positions with a sl and tp and close my cAlgo-instance, the sl and tp are considered / executed nevertheless?

2. Regarding my first question: at the moment the sl set by ExecuteMarketOrder() would be currently triggered at "default trade side" so at Ask with a buy-position and at Bid with a sell-position and the same with tp - is that correct? And would it be possible to control that "is-triggered-at-side"-option via cAlgo in my bot, so that i can change the serverside-triggering at sl from Ask to Bid and also at tp from Ask to Bid (here in this example for a buy position)?

Thanks in advance.

Best Regards,

andi21


@andi21
Replies

Spotware
11 Aug 2017, 10:58

Hi andi21,

Thanks for your questions.

1) Stop Loss and Take Profit are executed on the server no matter in which platform you set them, cAlgo or cTrader. It is Advanced Stop Loss and Advanced Take Profit that require cTrader to be running. See more info here http://help.spotware.com/trading/positions#advanced_take_profit

2) Regarding the trade side of stop loss, this is something that will be included in a future release of cAlgo.

Best Regards,

cTrader Team


@Spotware

andi21
11 Aug 2017, 11:08

Hi Spotware,

thank you for the answers - now it is clear how it is working.

Can you also answer the question in the second point, please?

at the moment the sl set by ExecuteMarketOrder() would be currently triggered at "default trade side" so at Ask with a buy-position and at Bid with a sell-position and the same with tp - is that correct?

 Best Regards,

andi21


@andi21

andi21
11 Aug 2017, 11:34

Hi,

i just thought, that i could also answer the question by myself and made a simple test-bot.

The answer to my quote (see above) is:

Yes, that is correct.

So the pips passed to ExecuteMarketOrder (slPips and tpPips) are calculated with the Symbol.Ask if a buy-Order is done and Symbol.Bid if a sell-Order is done (so "Default-Trade-Side" is used).

Best Regards,

andi21


@andi21

alexanderrobillos90@gmail.com
12 Dec 2018, 06:44

RE:

Spotware said:

Hi andi21,

Thanks for your questions.

1) Stop Loss and Take Profit are executed on the server no matter in which platform you set them, cAlgo or cTrader. It is Advanced Stop Loss and Advanced Take Profit that require cTrader to be running. See more info here http://help.spotware.com/trading/positions#advanced_take_profit

2) Regarding the trade side of stop loss, this is something that will be included in a future release of cAlgo.

Best Regards,

cTrader Team

can you address my problem sir please.
https://ctrader.com/forum/ctrader-support/14677?page=1#2


@alexanderrobillos90@gmail.com