Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
put a "var" in front of the "account = " on line 3463. you have to declare that account is a variable before you start trying to use it. that should make the other problems go away
Can you help answer these questions from other members on NexusFi?
Added the EventHandlers.. I think that's what they are...and cleared up the previous compile errors. But now one of the EventHandlers seems to have a syntax problem. See attached....
Ok... kind of got all that working enough to find out the "MarketPosition" is not the parameter that I want. It does something strange. When I enter long... MarketPosition is "Long". that's good. But when I close that position, MarketPosition says "Short". And when I'm flat, there are no more MarketPosition updates using PositionUpdate.
So I'm back to looking at Executions and focusing on "Position" in the most recent Execution update. The Positiion parameter is numerical and represents a negative or positive number for short or long and zero if flat. But I need to select the most recent execution from the collection and still not sure how to do that.
I've been looking at LinQ methods but no idea which syntax to use.
It's too hard to help you because you're too inexperienced with programming. You should learn C# and some object-oriented programming before trying to get good at Ninjascript.
ChartMinder is a NinjaTrader7 indicator for capturing chart images from single or grouped charts for local logging or online posting. It follows in the footsteps of vvhg's vvScreenShot and breaks new ground, hopefully with much more to follow.
I really appreciate your help Shodson, but just to let you know, I'm not a complete beginner. I've been learning C# since I first started working with NinjaTrader 3 years ago. I've learned a lot, but being in an unsupported area of NinjaScript makes this part more difficult. Ive done a few things with collections before but they are not second nature to me. I just need bread crumbs to keep my going the the right direction.
Last night I was looking at the trace file and found what I think will work. I was troubled because "ExecutionUpdateEventArgs" didn't have what I was looking for. But in the trace file I found there was another ExecutionUpdateEventArgs which is ExecutionUpdateEventArgs2. Refer to the attachment. It has the "Position" parameter that I want. Triggering on that even I will get the latest position information for the instrument I'm interested in.
I tried to add the code but during the compile I get an error. Does anyone know how to get "ExecutionUpdateEventArgs2" ?