Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Unhandled exception: unable to read beyond the end of stream

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

    Unhandled exception: unable to read beyond the end of stream

    Hello;

    I want to work with a DLL file to export historical data from an other trading plateform. But I have the error message: "Unhandled exception: unable to read beyond the end of stream" (see the added image).

    This is a part of code:
    protected override void OnStateChange()
    {
    if (State == State.SetDefaults)
    {
    .......
    }

    else if (State == State.Configure)
    {
    string connectionString = "Server=PCAM1;Database=NinjaTrader_ExportHistorica lData;User Id=sa;Password = n2Ls5kiKojV3839S37rT; ";
    export = new ExportHD(connectionString);
    Log("_____________---------------State = State.Configure---------------_____________", LogLevel.Information);

    }
    }


    tected override void OnBarUpdate()
    {
    export.connect("127.0.0.1", 7496, 0);
    try
    {
    export.exportHistoricalData(1, symbolDetails, EndDateTime, Duration, BarSizeSetting, WhatToShow, UserRTH, 1);
    }
    catch (Exception e)
    {
    Log("_____________---------------Exception message = " + e.Message + "---------------_____________", LogLevel.Information);
    }
    finally
    {
    export.disconnect();
    }
    }
    I wish if you can help me to resolve that
    Attached Files

    #2
    Hello laadari,

    Thank you for your post.

    Please provide further details on what you are attempting.

    Are you attempting to export NinjaTrader Historical Data? Or another platforms?
    Are you trying to export from the .ncd files? Or from a .csv or text based file?

    Comment


      #3
      Thinks _PatrickH;

      I wanna export historical data from IB plateform using NT8 indicators.

      IB give us an API in C# to work with it, so I export the data directly.

      Comment


        #4
        Hello laadari,

        Thank you for your response.

        We would not have any information on this set up and would not have any examples either. I would leave this open to see if any other members of the forum have tried this in NinjaTrader 8 indicators.

        Comment


          #5
          Originally posted by NinjaTrader_PatrickH View Post
          Hello laadari,

          Thank you for your response.

          We would not have any information on this set up and would not have any examples either. I would leave this open to see if any other members of the forum have tried this in NinjaTrader 8 indicators.
          Your welcome;

          Me too I will keep trying until get it work. And I will let you know.
          Think you Patrick.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by wzgy0920, 04-20-2024, 06:09 PM
          2 responses
          26 views
          0 likes
          Last Post wzgy0920  
          Started by wzgy0920, 02-22-2024, 01:11 AM
          5 responses
          32 views
          0 likes
          Last Post wzgy0920  
          Started by wzgy0920, Yesterday, 09:53 PM
          2 responses
          49 views
          0 likes
          Last Post wzgy0920  
          Started by Kensonprib, 04-28-2021, 10:11 AM
          5 responses
          192 views
          0 likes
          Last Post Hasadafa  
          Started by GussJ, 03-04-2020, 03:11 PM
          11 responses
          3,234 views
          0 likes
          Last Post xiinteractive  
          Working...
          X