I am new to NT8 but experienced in C#. I want to have an indicator that will do the following:
provided I open an order via the UI, it will calculate a distance for a stop loss order, and it will place the stop order.
Then on each bar it will recalculate and if needed, it will trail if needed
I managed to get this working by creating the order but it is not able to update it when the trailing price changes, using this code:
stopOrder.StopPrice = currentStopPrice;
account.Change(new List<Order> { stopOrder });
stopOrder is the one that was created earlier with account.CreateOrder(), stored in a field in the indicator class,
The only way I managed to do it was by deleting the order and creating it again every time I want to change it.
My questions to you more experienced guys:
1. is the indicator supposed to be able to modify such a stop order (instead of recreating it each time) and if yes how?
2. if not, assuming I stay with the working version (indicator that recreates the stop order), would that be fawned upon by the NT broker or prop firms for submitting too many orders (if we work let's say on a fast timeframe chart and there are several modifications per minute)?
Any other ideas?
Thanks

Comment