Deal.ExecutionPrice
property · Deal · cAlgo.API Since 5.1
DesktopCLICloud
Returns deal execution price if deal is filled otherwise null.
Definition
double? ExecutionPrice {get;}
deal.ExecutionPrice: float | None
Returns double?
Examples
var trade = History.FindLast("myLabel");
if (trade != null && trade.ClosingDeal.ExecutionPrice.HasValue)
Print("Closing deal executed at {0}", trade.ClosingDeal.ExecutionPrice.Value);
trade = api.History.FindLast("myLabel")
if trade is not None and trade.ClosingDeal.ExecutionPrice is not None:
api.Print(f"Closing deal executed at {trade.ClosingDeal.ExecutionPrice}")