Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Connection Source

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

    Connection Source

    I have an indicator that writes out the Prior Day OHLC plus today's "cash open" price (future's contracts)-- To get the price data for cash open I am running this on a 1-minute chart and capturing the open of the 7:31 bar (Mountain time)--

    I have 2 connections--Zen-fire and Kinetick -- assume I only have one connected at any one time--

    As I run this indicator on a chart (and it writes to a file)--is the historical data coming first from the database (stored values) if there are any--or is it rebuilding these values each time I run it using the then current connection's datafeed?

    If the latter, is there anyway for me to retrieve which connection is 'connected' -- from a built-in method/property? This way I can also write the source of the data to the file.

    If there's not a built-in function-is there a way to do this at all using other (non-NinjaTrader) functions in C#?
    Jim-Boulder
    NinjaTrader Ecosystem Vendor - Elephant Tracks

    #2
    Hello Jim-Boulder,

    Thank you for your post.

    Historical Data will reload from the data provider under these three conditions:
    1. The End date parameter of the Data Series window contains the current day
    2. The End date parameter of the Data Series window contains the last day of data available in your data repository
    3. The data repository contains no data within 3 days of the first day loaded in the chart

    You can find additional information at the following link on when historical is loaded from the data feed provider: http://www.ninjatrader.com/support/h...rical_data.htm

    The following line is unsupported code but will tell you in the Output Window (Tools > Output Window) what connection is connected:
    Code:
    Print(Bars.MarketData.Connection.Name.ToString());
    Please let me know if I may be of further assistance.

    Comment


      #3
      You da man! Thanks.
      Jim-Boulder
      NinjaTrader Ecosystem Vendor - Elephant Tracks

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by argusthome, Yesterday, 10:06 AM
      0 responses
      20 views
      0 likes
      Last Post argusthome  
      Started by NabilKhattabi, 03-06-2026, 11:18 AM
      0 responses
      18 views
      0 likes
      Last Post NabilKhattabi  
      Started by Deep42, 03-06-2026, 12:28 AM
      0 responses
      14 views
      0 likes
      Last Post Deep42
      by Deep42
       
      Started by TheRealMorford, 03-05-2026, 06:15 PM
      0 responses
      9 views
      0 likes
      Last Post TheRealMorford  
      Started by Mindset, 02-28-2026, 06:16 AM
      0 responses
      38 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Working...
      X