Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Unwanted order entry
Collapse
X
-
Unwanted order entry
After enabling strategy and waiting for chart to finish calculating data as soon as it finishes it automatically enters a trade with no stop or profit target. How do I get rid of this annoying problem strategy works fine but I closed trade manually and now when I reset for another trade with enable I get the unwanted order entry as soon as it is don calculating. Please HELP!Tags: None
-
I don't place the order it comes up automatically. I closed trade manually before it hit my stop loss. Have to re enable strategy as box is unchecked after closing trade. Chart calculates when done calculating order is entered no profit target no stop. Did strategy again from scratch works fine in both directions sell and buy withmy profit target and stop, but when I close trade manually to prevent hitting stop loss it does the order entry when I reset. Thought someone might have run into this problem before and was something simple I was missing. Any help is appreciated thanks for viewing and answering post
Comment
-
New setup will not engage because strategy has to be enabled again and once the strategy is done calculating the unwanted order entry comes up and all that happens is I watch the PNL go up and down. Simple strategy from ninjacators in Turkey. MACD with ninzarenko chart by cutey atesman ordered some robots from hi. And this strategy was on one of the videos he sent me.
Comment
-
Just entered settings into ninjatrader strategy builder did not think about the code. I was having a similar problem automating a footprint chart from orderflows with Markers and could not figure out the conflict between the automated strategy and using the flatten feature to clear the order but it will not reset to automated trades before having to check enable box and cycle starts all over again. Will look at code in the morning as I am at work right now.
Comment
-
GroundHog241,
Thank you for your post.
Please keep in mind that clicking the "Close" button to close a position for an account/instrument that has a strategy running will disable the strategy. This is in the "Tips" section of the following page:
https://ninjatrader.com/support/help...ategy.htm#HowT oRunAninjascriptStrategyInAChart
Since your strategy is opening a position without the stop loss or profit target immediately upon enabling it, I am curious about the following questions:- What version of NinjaTrader are you using? Please provide the entire version number. This can be found under Help -> About (Example: 8.?.?.?)
- Who are you connected to? This is displayed in green in the lower-left corner of the Control Center window.
- What instrument(s) (and expiry if applicable) have you selected?
- What Data Series Type have you selected? Example: Tick, Minute, Day
- You mentioned NinjzaRenko, correct?
- Is your strategy a multi-instrument or multi-time frame strategy?
- When you right-click the Chart and select Strategies, what setting do you have selected for the "Start behavior" dropdown menu?
- Do you receive an error on the screen? Are there errors on the Log tab of the Control Center? If so, what do these errors report?
Comment
-
I have come across others that have had similar problems because the action of using the close button on the order chart is outside the parameters of the strategy I am using is the reason for the problem posts on the forum have stated that it disables the strategy and throws it out of sync. Solution has been suggested to write code for a close button on a toolbar in the strategy itself which makes a great deal of sense. I have some experience with Python programming but have not used C# before but hopefully the two languages are similar other than differences in syntax. The toolbar was downloaded from ninjatrader ecosystem by ninjatrader_zacheryG. Hopefully changing the coding a little will make the buttons a manual way of closing the trade in the strategy without affecting it the way it does when using the close button on ninjatraders order chart. Thank you for your interest Emily I will try to start coding on Saturday as I will be from regular work. If you know of the procedure for coding a toolbar button like this please give me some direction it would be greatly appreciated as this would not only help this strategy but all the others I use in the future that are automated. Thanks Jeffry W Smith
Comment
-
At work so I will try to make it quick ?attest version of ninjatrader 8, 1 minute frame, ES06-23, Just a ninzarenko chart set 10/1. Regular MACD settings, renko changes directions at MACD crossover long and short. Stop-loss set at 15, there can be a profit target set but presently have it set to run until turnaround whether buy or sell so trade can run longest time course. Problem sometimes turnaround from buy to sell or sell to buy you can tell from delta on footprint chart trade will go in wrong direction, hence the need fe or manual pclose of trade since I can usually can tell before it hits stop loss. Back to work
Comment
-
Yes, that is probably what you want to do if you want the strategy to continue running - add a button to either the chart or the toolbar such that when you push the button your STRATEGY closes the trade rather than you closing the trade from outside the strategy. It is your intervention from OUTSIDE the strategy that causes the strategy to be disabled but if it is the strategy that decides to close the trade (because you pushed the button) it is not out of sync because it is in the expected position and there were no unexpected external interventions that would knock it offline.
Comment
-
Hello GroundHog241,
Thank you for your insight.
If you would like to add a button to your chart, I suggest checking out the reference sample for creating WPF modifications from an indicator that may be found here:
The same ideas and use cases may be applied in a strategy as well. You could create a button with a button press event, and when the button is pressed you could set it up to check your strategy's position (potentially save it in a variable) and toggle a bool that will cause logic to be triggered to close the position in your strategy script.
Please feel free to reach out if you need any additional assistance.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, 03-13-2026, 05:17 AM
|
0 responses
99 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
154 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
82 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
55 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
72 views
0 likes
|
Last Post
|

Comment