Property addition for position: Give expected closingprice of position. (buy:bid,Sell:ask)

Created at 24 Feb 2020, 14:50
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!
GE

genappsforex

Joined 25.11.2019

Property addition for position: Give expected closingprice of position. (buy:bid,Sell:ask)
24 Feb 2020, 14:50


Please make some additions to the Position Class

It would save us making & maintaining userdefined Extentions and make code more readable.

suggestions for properties:

  1. public readonly double PointPrice {get;} //(is already there but hidden/inaccessible);
  2. public readonly double BreakEvenPrice //{get;}(incl. commission and swaps) ;
  3. public readonly bool IsBuy;
  4. public readonly bool IsSell;
  5. public string CloseReason {get/set};

suggestions for methods:

  1. public TradeResult ClosePart(int Volume);

suggestions for RobotClass:

  1.   public static double RequiredMargin(Symbol symbol, double volumeInUnits, TradeType tradeType)

  

Keep up the good work !
:-)

 


@genappsforex
Replies

PanagiotisCharalampous
24 Feb 2020, 14:58

Hi genappsforex,

All positions have a TakeProfit and StopLoss property which are in absolute prices. What other closing price do you need?

Best Regards,

Panagiotis 

Join us on Telegram

 


@PanagiotisCharalampous

genappsforex
24 Feb 2020, 15:18

RE:

PanagiotisCharalampous said:

Hi genappsforex,

All positions have a TakeProfit and StopLoss property which are in absolute prices. What other closing price do you need?

Best Regards,

Panagiotis 

Join us on Telegram

 

Often we do not work with absolute prices but with distances between either entryprice or currentprice
Now we use Extentions for that but it would be nicer if it was native

 


@genappsforex