Is there a way to save user defined ninjiscript variables to file, so on restarting the program, the variables are reloaded?
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
Saving Variables Between NT Sessions
Collapse
X
-
Saving Variables Between NT Sessions
If I shutdown the computer at the end of the trading day and then relaunch the program just prior to the trading day, what system variables are saved to file and reloaded on relaunch? Is there any NT documentation on this? How does this affect an autotrading?
Is there a way to save user defined ninjiscript variables to file, so on restarting the program, the variables are reloaded?Tags: None
-
In NinjaTrader 6.5, not much is saved when you shut down. All strategies settings are lost, so when you start it up again, you need to input all settings again.
NT7 will address this and save strategy information during a shutdown so it is there upon restart.
If you'd like to save variables to a file, please take a look at the samples titled Using StreamWriter to write to a text file and Using StreamReader to read from a text file.AustinNinjaTrader Customer Service
-
Austin, Thanks for the quick reply.
My strategy presents multiple buy and sell signals (triggers), so I want to enter a position on the first such trigger, then ignore any subsequent triggers while waiting for the first trigger to exit the position.
I assumed a need to set up a boolean variable for program flow control for directing which trading opportunity to look for. Do you know of another approach for handling this?
Originally posted by NinjaTrader_Austin View PostIn NinjaTrader 6.5, not much is saved when you shut down. All strategies settings are lost, so when you start it up again, you need to input all settings again.
NT7 will address this and save strategy information during a shutdown so it is there upon restart.
If you'd like to save variables to a file, please take a look at the samples titled Using StreamWriter to write to a text file and Using StreamReader to read from a text file.
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by nandhumca, Today, 03:41 PM
|
0 responses
1 view
0 likes
|
Last Post
by nandhumca
Today, 03:41 PM
|
||
Started by The_Sec, Today, 03:37 PM
|
0 responses
3 views
0 likes
|
Last Post
by The_Sec
Today, 03:37 PM
|
||
Started by GwFutures1988, Today, 02:48 PM
|
1 response
5 views
0 likes
|
Last Post Today, 03:09 PM | ||
Started by ScottWalsh, 04-16-2024, 04:29 PM
|
6 responses
32 views
0 likes
|
Last Post
by ScottWalsh
Today, 02:57 PM
|
||
Started by frankthearm, Today, 09:08 AM
|
10 responses
36 views
0 likes
|
Last Post
by frankthearm
Today, 02:54 PM
|
Comment