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
Get last execution price
Collapse
X
-
Get last execution price
Hey guys i am using the managed method for orders. I was wondering how to get the last execution price for an entry. I have a series of orders like, Enterlong(1) then another EnterLong later in the code. I would like to get the last execution price after the second entry. How do i do this? I realize i could use position.avgprice but that only gives me the average of the two prices not the last execution.Tags: None
-
Hello,
Thank you for the question.
To get a specific execution, you would need to use the OnExecution override. This is called for each execution the strategy produces. http://ninjatrader.com/support/helpG...ub=onexecution
There are some examples in the help guide to get you started in using this, also this would only be available in manual coding so if you are using the Wizard this would not be an option unless you unlock the code.
I look forward to being of further assistance.JesseNinjaTrader Customer Service
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by IanS00, 03-27-2024, 11:24 AM
|
2 responses
11 views
0 likes
|
Last Post Today, 02:00 AM | ||
Started by Mariawilcoxi, Today, 01:32 AM
|
0 responses
3 views
0 likes
|
Last Post
by Mariawilcoxi
Today, 01:32 AM
|
||
Started by gleichnerany, Today, 01:17 AM
|
0 responses
5 views
0 likes
|
Last Post
by gleichnerany
Today, 01:17 AM
|
||
Started by WHICKED, 03-27-2024, 12:33 PM
|
4 responses
46 views
0 likes
|
Last Post Today, 12:28 AM | ||
Started by f.saeidi, Today, 12:12 AM
|
0 responses
7 views
0 likes
|
Last Post
by f.saeidi
Today, 12:12 AM
|
Comment