I have several different exit strategies with counters that keep track of the number of times each exit strategy is executed. But I only want to keep track of the exits when it's a realtime trade and not including the days that are loaded prior to the realtime executions. How do I go about? Thanks.
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Realtime executions
Collapse
X
-
Realtime executions
Hi,
I have several different exit strategies with counters that keep track of the number of times each exit strategy is executed. But I only want to keep track of the exits when it's a realtime trade and not including the days that are loaded prior to the realtime executions. How do I go about? Thanks.Tags: None
-
Hello 2Look4me,
Thanks for your post.
You can use the system bool Historical as part of the conditions to increment your counter.
Reference: https://ninjatrader.com/support/help...historical.htm
For example:
if (your condition to exit this exit strategy)
{
if (!Historical) // if NOT historical, meaning must be realtime (or market replay)
{
myExitStrategyCounter++; // increment my exit strategy colunter
}
// exit strategy stuff
}Paul H.NinjaTrader Customer Service
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by Lele2k24, Yesterday, 11:24 AM
|
11 responses
35 views
0 likes
|
Last Post
by Lele2k24
Today, 03:00 PM
|
||
Started by RaygunWizzle, Yesterday, 08:52 PM
|
3 responses
11 views
0 likes
|
Last Post Today, 02:50 PM | ||
Started by Tim-c, Today, 08:36 AM
|
4 responses
14 views
0 likes
|
Last Post Today, 02:45 PM | ||
Started by JohnS52, 03-22-2024, 08:06 AM
|
4 responses
28 views
0 likes
|
Last Post
by JohnS52
Today, 02:30 PM
|
||
Started by carnitron, 03-25-2024, 01:59 PM
|
11 responses
53 views
0 likes
|
Last Post
by carnitron
Today, 02:18 PM
|
Comment