Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Question about AtmStrategyCreate

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

    Question about AtmStrategyCreate

    Hello,

    I'm developing a strategy that uses multi-time frames and multi-data series.

    I know that you can reference the barsInProgressIndex when submitting an order. As seen below:
    Code:
    EnterLong(int barsInProgressIndex, int quantity, string signalName)
    Are you able to reference barsInProgress index when submitting an order using AtmStrategyCreate()? I don't see it on the reference page.
    ​​​​​​​
    Code:
    AtmStrategyCreate(OrderAction action, OrderType orderType, double limitPrice, double stopPrice, TimeInForce timeInForce, string orderId, string strategyTemplateName, string atmStrategyId, Action<Cbi.ErrorCode, string> callback)
    Any help would be appreciated.

    Thank you!

    #2
    Hello devatechnologies,

    Thank you for your post.

    There is no barsInProgress parameter, however, you can use a BarsInProgress condition to submit the orders to an additional bars object.





    I tested this by making a copy of SampleAtmStrategy, adding an additional series in the strategy, and then putting the existing code in a BarsInProgress condition.

    Code:
    //value of 1 represents the additional series added in State.Configure 
    if (BarsInProgress == 1)
    {
    //logic for submitting and handling atm goes here
    }
    Please let us know if you have any further questions.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    113 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    60 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    40 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    43 views
    0 likes
    Last Post TheRealMorford  
    Started by Mindset, 02-28-2026, 06:16 AM
    0 responses
    81 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X