I'm creating an AtmStrategy from an indicator, by setting up an order using Account.CreateOrder() and then using NinjaTrader.NinjaScript.AtmStrategy.StartAtmStrate gy(templateName, order);
This works very well. The AtmStrategy fills and proceeds to manage its position without any further ado from my code.
But, if I now want to control the stoploss and target myself, how can I do that? I need to know the AtmStrategyId string so that I can use the AtmStrategyChangeStopTarget() method.
The StartAtmStrategy() returns an instance of AtmStrategy, which contains some information but NOT the AtmStrategyId string. Is there a way to get that string?
An alternative would be to change the orders directly in the account. I have tried that by finding the orders and setting the StopPrice of the order to a new value then using Account.Change(ordersList) but I'm not seeing the orders change. Perhaps the AtmStrategy overrides the changes - I don't know for sure.
Thanks in advance for any assistance,
saltminer
Comment