How to define e-mail or SMS alert for condition “Limit trade executed” - I place only Sell and Buy limit orders. The ATM doesnt give me option to define SL and TP based on market levels. It is pe-set. I am thinking of creating an alert when the limit order is executed, then manually adjust the SL, TP levels to meet the market levels. I dont see an option to set alerts for “Limit oder executed” from the Chart Alerts memu or in documentation. Is this feasible?
Yes, that’s doable for your manual ATM entries. A fill is an execution event, not a chart price crossing. So I’d use an account-level ExecutionUpdate listener for manual orders. A strategy’s OnExecutionUpdate sees its own strategy-managed orders only. I’d filter for your entry orders, handle partial fills, and deduplicate by execution ID. Then it would send an email through your configured share service. SMS depends on what your provider supports. Details here: NinjaScript > Language Reference > Add On > Account > ExecutionUpdate Do you want one alert at the first partial fill or only when it’s fully filled?
There’s also a way to skip the alert if the real problem is the preset stop and target. In an ATM strategy those are tick distances from your fill, and a limit fills at your price or better, so you can work them out before you place the order. Count the ticks from your limit price to your stop level and to your target level, then enter those numbers. Choosing Custom in the ATM strategy dropdown lets you set them for that one order without saving a template. That way the bracket lands on your levels when the limit fills, and nothing has to be adjusted by hand afterward.