i need to retrieve the AvgEntryPrice for the order that just got filled.
So i did an override of the OnExecution() method
but now i have a dilemna, what is the difference between
IExecution.Price
and
IExecution.Order.AvgFillPrice
if IExecution.Price is the total price of the operation
then does IExecution.Price / IExecution.Quantity give the same result as the Order.AvgFillPrice ?
(with a round2tick() i suppose)
Thank you
edit:
Also, when OnExecution() is called
do i need to check the Order.OrderState ? Or will they all be OrderState.Filled ?
Comment