RearmAlert()

View as Markdown

Definition

Rearms an existing alert event by the string “id” parameter created via the AlertCallback() method. A NinjaScript generated alert by may need to be rearmed after the alert is triggered depending on the Alert()‘s rearmSeconds parameter.

The NinjaScriptBase has a non-static method implemented with the same name. Please see the RearmAlert() method for Indicator or Strategies.

Method Return Value

This method does not return a value.

Syntax

NinjaTrader.NinjaScript.Alert.RearmAlert(string id)

Parameters

ParameterDescription
idA unique string id representing an alert id to reset

Examples

1if (resetCondition)
2{
3 NinjaTrader.NinjaScript.Alert.ResetAlertRearmById("someId");
4 resetCondition = false;
5}