Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

BarsInProgress

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

    BarsInProgress

    Hi, i'm trying to understand what barsinprogress command does.

    so if i add
    Code:
    if (BarsInProgress  == 1)
                {
                // Condition set 1
                if ((Position.MarketPosition == MarketPosition.Flat)
                    && ......................))
                {
                    EnterLongLimit(DefaultQuantity, ......., "");
                }
    vs
    without the barsinprogress; what is the difference if cobc=true

    will it wait until 1 bar has passed after my exit and then analyze the logic to reenter the market or something? sorry if this is a super basic question. i have it in one of my strategy and it does exactly what i want it to do... but i just dont understand logically what this command does..

    #2
    Originally posted by calhawk01 View Post
    Hi, i'm trying to understand what barsinprogress command does.

    so if i add
    Code:
    if (BarsInProgress  == 1)
                {
                // Condition set 1
                if ((Position.MarketPosition == MarketPosition.Flat)
                    && ......................))
                {
                    EnterLongLimit(DefaultQuantity, ......., "");
                }
    vs
    without the barsinprogress; what is the difference if cobc=true

    will it wait until 1 bar has passed after my exit and then analyze the logic to reenter the market or something? sorry if this is a super basic question. i have it in one of my strategy and it does exactly what i want it to do... but i just dont understand logically what this command does..
    FYI- my entry orders with or without are the same

    Comment


      #3
      BarsInProgress is for multiseries.

      If you don't understand NT documentation, try else where





      Originally posted by calhawk01 View Post
      Hi, i'm trying to understand what barsinprogress command does.

      so if i add
      Code:
      if (BarsInProgress  == 1)
                  {
                  // Condition set 1
                  if ((Position.MarketPosition == MarketPosition.Flat)
                      && ......................))
                  {
                      EnterLongLimit(DefaultQuantity, ......., "");
                  }
      vs
      without the barsinprogress; what is the difference if cobc=true

      will it wait until 1 bar has passed after my exit and then analyze the logic to reenter the market or something? sorry if this is a super basic question. i have it in one of my strategy and it does exactly what i want it to do... but i just dont understand logically what this command does..

      Comment


        #4
        The OnBarUpdate() is generally called for all your series including the added ones, with BarsInProgress you can filter for which series is calling the method to update.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Hwop38, 05-04-2026, 07:02 PM
        0 responses
        160 views
        0 likes
        Last Post Hwop38
        by Hwop38
         
        Started by CaptainJack, 04-24-2026, 11:07 PM
        0 responses
        307 views
        0 likes
        Last Post CaptainJack  
        Started by Mindset, 04-21-2026, 06:46 AM
        0 responses
        245 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by M4ndoo, 04-20-2026, 05:21 PM
        0 responses
        348 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by M4ndoo, 04-19-2026, 05:54 PM
        0 responses
        178 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Working...
        X