Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to get the first trade of an account?

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

    How to get the first trade of an account?

    Hello.

    How can I get the first historical trade of an account?

    I can get the first trade of a strategy, fetching:
    Code:
    Trade firstTrade = SystemPerformance.AllTrades[0];
    , but I need the same of my account, not the strategy.

    Thank you very much.

    #2
    Hello,

    Thank you for the post.

    In this case, because you want the actual account trades this would not be an item Strategies have by default. All of the reporting items in Strategies specifically will relate to only the running instance of that specific strategy. To utilize the Account, you could reference the addon account methods: http://ninjatrader.com/support/helpG...ount_class.htm

    You could use the following example to loop through an accounts orders:


    To access the account, please see the following example as this step is omitted in the above samples, mainly just the portion noted "// Find our Sim101 account": http://ninjatrader.com/support/helpG...ount_class.htm

    Please let me know if I may be of additional assistance.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Today, 05:17 AM
    0 responses
    52 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    130 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    70 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    44 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    49 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X