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 Mindset, 04-21-2026, 06:46 AM
    0 responses
    87 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    128 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    65 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    117 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    67 views
    0 likes
    Last Post PaulMohn  
    Working...
    X