Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

building OIF dynamically from an indicator

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

    building OIF dynamically from an indicator

    Hello,

    I want to build and write a OIF file from an indicator.

    In this case only to Close a Position.

    All I need is the Account and the Instrument name....

    I believe I can get the account from Instrument.FullName.

    But where can I dynamically get the Account in CharTrader from the Indicator code?

    I can't seem to find this in the documentation or forum.

    Thank you.

    #2
    Turtle Trader,

    Unfortunately there is no supported way to get account information from an Indicator. You could do this from a strategy however.
    Adam P.NinjaTrader Customer Service

    Comment


      #3
      ok

      Ok, well perhaps I can have a strategy tell the indicator what the account is...

      Can you please point me to the correct instruction on how to get the account info...thx

      Comment


        #4
        Turtle Trader :

        The Account class is not exposed in an indicator, like it is exposed in a strategy. You can refer to this code to get an idea how to expose the Account class, but nothing we would support officially.
        Adam P.NinjaTrader Customer Service

        Comment


          #5
          ok

          thank you, this should do it

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by CarlTrading, 03-31-2026, 09:41 PM
          1 response
          81 views
          1 like
          Last Post NinjaTrader_ChelseaB  
          Started by CarlTrading, 04-01-2026, 02:41 AM
          0 responses
          42 views
          0 likes
          Last Post CarlTrading  
          Started by CaptainJack, 03-31-2026, 11:44 PM
          0 responses
          64 views
          2 likes
          Last Post CaptainJack  
          Started by CarlTrading, 03-30-2026, 11:51 AM
          0 responses
          66 views
          0 likes
          Last Post CarlTrading  
          Started by CarlTrading, 03-30-2026, 11:48 AM
          0 responses
          54 views
          0 likes
          Last Post CarlTrading  
          Working...
          X