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 fernandobr, Today, 09:11 AM
          0 responses
          0 views
          0 likes
          Last Post fernandobr  
          Started by itrader46, Today, 09:04 AM
          1 response
          3 views
          0 likes
          Last Post NinjaTrader_Clayton  
          Started by timmbbo, Today, 08:59 AM
          0 responses
          2 views
          0 likes
          Last Post timmbbo
          by timmbbo
           
          Started by bmartz, 03-12-2024, 06:12 AM
          5 responses
          33 views
          0 likes
          Last Post NinjaTrader_Zachary  
          Started by Aviram Y, Today, 05:29 AM
          4 responses
          14 views
          0 likes
          Last Post Aviram Y  
          Working...
          X