I'm trying to prevent multiple entries being created in the Alerts Log window when the chart is reloaded by checking the list of existing ID's.
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
How to check if Alert Log > ID exists
Collapse
X
-
How to check if Alert Log > ID exists
How do you check if an Alert() ID already exists? https://ninjatrader.com/support/help.../nt8/alert.htm
I'm trying to prevent multiple entries being created in the Alerts Log window when the chart is reloaded by checking the list of existing ID's.Tags: None
-
I don't think you can.
If you set rearmSeconds high enough, I dunno, say 5 or 15 seconds,
does that do anything to help? Have you tried this?
Multiple entries in the Alerts window using the same Id is a feature.
That is, the Alert() method expects each Alert to use the same Id,
that's how rearmSeconds works.
If you have 10 different calls to Alert(), each call should have it's own
unique string Id, but still, each string Id is supposed to be a constant
string value -- again, that's how Alert knows to wait the duration
specified by rearmSeconds -- any call to Alert() inside the unarmed
period would be ignored.
If you're seeing too many, I presume the only recourse is to redesign
your criteria or employ a higher rearmSeconds value.
-
Hello zacharydw00,
Unfortunately, I am not aware of a public collection of the triggered alerts (or their IDs) that be accessed from NinjaScript.
bltdavid is providing good information. Setting the frequency the Alert can be triggered by setting the Re-arm seconds would be the supported functionality.Chelsea B.NinjaTrader Customer Service
Comment
-
Thanks guys, will try.
I though 'rearmSeconds' was for audio only, but I see that is not specifically stated.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
653 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
370 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
109 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
574 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
577 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment