Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Help with Account.ExecutionUpdate , determining entry and exits

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Help with Account.ExecutionUpdate , determining entry and exits

    i am writing some code to send tweets, I have it mostly working. if e.execution.IsEntry send tweet then another if e.execution.IsExit send tweet. Example I short ES and it sends tweet ES Short @ 4001 then I exit the position with Close and I get tweet: ES exited at 3990 then i also get tweet: Long at 3990 how do eliminate the second tweet, mind you i could be making multiple entries at different times then closing them at different times, i thinking i need a unique identifier.

    #2
    Hello set2win,

    You would likely need to use some form of your own logic to determine the tweet was already sent or use the Long execution event instead.

    If you are using the execution update event that will catch all executions so the code would be called each time an execution is observed and multiple times for part filled orders. You can use a Print to print out the execution information to see exactly what series of events is happening and also to see the values of the execution. That may help to form logic to filter the specific execution's you wanted to know about. You can see the avaliable properties here: https://ninjatrader.com/support/help...tsub=execution

    Comment


      #3
      thinking of some kind of array variable that gets flushed each day, then as each trade entry is made it populates the array ie tradeEntry = Count1, Count2, then a check if not found send tweet, is this over thinking it

      Comment


        #4
        Hello set2win,

        That could work depending on what executions you need to track. The best way forward would be to use prints to identify the specific events for each scenario you wanted to track and then use that information to build out your logic. You can use any C# code you want to complete the task which could include arrays or lists to keep track of what has been observed already.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        571 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        330 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        548 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        549 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X