Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Unhanded exceptions

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

    Unhanded exceptions

    Hi

    I am getting unhanded exception even for the build in Strategies when I add simple Print calls

    2017-09-11 01:11:51:526 Object reference not set to an instance of an object.
    2017-09-11 01:11:51:528 System.NullReferenceException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object.
    at MS.Internal.TextFormatting.LineServicesCallbacks.S etChpFormat(TextRunProperties runProp, LsChp& lschp)
    at MS.Internal.TextFormatting.LineServicesCallbacks.F etchRunRedefined(IntPtr pols, Int32 lscpFetch, Int32 fIsStyle, IntPtr pstyle, Char* pwchTextBuffer, Int32 cchTextBuffer, Int32& fIsBufferUsed, Char*& pwchText, Int32& cchText, Int32& fIsHidden, LsChp& lschp, IntPtr& lsplsrun)
    --- End of inner exception stack trace ---
    at MS.Internal.TextFormatting.TextMetrics.FullTextLin e.FormatLine(FullTextState fullText, Int32 cpFirst, Int32 lineLength, Int32 formatWidth, Int32 finiteFormatWidth, Int32 paragraphWidth, LineFlags lineFlags, FormattedTextSymbols collapsingSymbol)
    at MS.Internal.TextFormatting.TextMetrics.FullTextLin e..ctor(FormatSettings settings, Int32 cpFirst, Int32 lineLength, Int32 paragraphWidth, LineFlags lineFlags)
    at MS.Internal.TextFormatting.TextFormatterImp.Format LineInternal(TextSource textSource, Int32 firstCharIndex, Int32 lineLength, Double paragraphWidth, TextParagraphProperties paragraphProperties, TextLineBreak previousLineBreak, TextRunCache textRunCache)
    at MS.Internal.TextFormatting.TextFormatterImp.Format Line(TextSource textSource, Int32 firstCharIndex, Double paragraphWidth, TextParagraphProperties paragraphProperties, TextLineBreak previousLineBreak)
    at ActiproSoftware.Windows.Controls.SyntaxEditor.Text Formatting.TextViewLineLayoutGroupFactory.#6lc(ITe xtView #N5b, ITagAggregator`1 #y9b, ITagAggregator`1 #z9b, TextRange #I, Double #hpi)
    at #m3b.#b4b.#8lc(ITextView #N5b, ITagAggregator`1 #y9b, ITagAggregator`1 #z9b, TextRange #I, Double #hpi)
    at #m3b.#b4b.#cmc(ITextView #N5b, ITagAggregator`1 #y9b, ITagAggregator`1 #z9b, Int32 #Oqc, Double #hpi, Double #Dzf, Double #Ezf, Boolean #ipi)
    at #m3b.#c4b.#pmc(ITextView #N5b, ITagAggregator`1 #y9b, ITagAggregator`1 #z9b, Size #Gzf, TextPosition #d9b, Boolean #Hzf, Boolean #ipi)
    at ActiproSoftware.Windows.Controls.SyntaxEditor.Prim itives.EditorView.PerformViewLineLayout()
    at ActiproSoftware.Windows.Controls.SyntaxEditor.Prim itives.EditorView.ArrangeOverride(Size finalSize)
    at System.Windows.FrameworkElement.ArrangeCore(Rect finalRect)
    at System.Windows.UIElement.Arrange(Rect finalRect)
    at System.Windows.ContextLayoutManager.UpdateLayout()
    at System.Windows.ContextLayoutManager.UpdateLayoutCa llback(Object arg)
    at System.Windows.Media.MediaContext.FireInvokeOnRend erCallbacks()
    at System.Windows.Media.MediaContext.RenderMessageHan dlerCore(Object resizedCompositionTarget)
    at System.Windows.Media.MediaContext.RenderMessageHan dler(Object resizedCompositionTarget)
    at System.Windows.Threading.ExceptionWrapper.Internal RealCall(Delegate callback, Object args, Int32 numArgs)
    at System.Windows.Threading.ExceptionWrapper.TryCatch When(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

    #2
    Hello toliss,

    Thank you for your post.

    Please send me your log and trace files so that I may look into what occurred. You can do this by going to the Control Center-> Help-> Mail to Platform Support. Ensuring 'Log and Trace Files' is checked will include these files. This is checked by default.

    Please refer this thread in the body of your email.

    I look forward to your response.

    Comment


      #3
      Hi

      Before you answered I found



      which sounds the same case to me, so I did what suggested there and now I cannot reproduce. Am I a sure however you already noted that something is strange there as this is not a standalone case for e.g here one more


      Anyway thanks for the answer when it comes again I will send to the support, hopefully I will not lose much of my time like this one as it was really hard to catch the exception cause it is not written to the trace all the time.

      Comment


        #4
        unfortunately the re installation suggested in related posts did not help, the exception came back after hiding like a virus for some time . I send you my trace

        Comment


          #5
          I finally found a solution after a short mail chat with Patrick where he said that Actipro problems are mostly solved with re-installation. Along with the previous posts I realized that even if I re-install NT the problem remain because I kept my old My Documents/NinjaTrader 8 folder. Therefore the solution was first to replace the NinjaTrader.Custom.csproj with a blank empty one from a new installation and if the problem remain apparently I have to blame the serialization settings of some of my templates.

          So finally I deleted all custom xml files from the NT directory and haven;t crashed since then! I do not know which setting or template results in such behavior but it is a logical explanation analyzing the data I had.

          Hope it helps someone

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by andrewtrades, Today, 04:57 PM
          1 response
          8 views
          0 likes
          Last Post NinjaTrader_Manfred  
          Started by chbruno, Today, 04:10 PM
          0 responses
          6 views
          0 likes
          Last Post chbruno
          by chbruno
           
          Started by josh18955, 03-25-2023, 11:16 AM
          6 responses
          436 views
          0 likes
          Last Post Delerium  
          Started by FAQtrader, Today, 03:35 PM
          0 responses
          7 views
          0 likes
          Last Post FAQtrader  
          Started by rocketman7, Today, 09:41 AM
          5 responses
          19 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Working...
          X