This project is read-only.

Exception is thrown when ChartPlot without explicitly set size

Mar 27, 2009 at 2:55 PM
is put on Canvas.


System.InvalidOperationException was unhandled
  Message="Переопределения измерений макета элемента \"System.Windows.Shapes.Path\" не должны возвращать значения PositiveInfinity для параметра DesiredSize, даже если в качестве доступного размера передано значение Infinity."
  Source="PresentationCore"
  StackTrace:
       в System.Windows.UIElement.Measure(Size availableSize)
       в System.Windows.ContextLayoutManager.UpdateLayout()
       в System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
       в System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork()
       в System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
       в System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
       в System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)
       в System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter)
       в System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
       в System.Windows.Threading.Dispatcher.WrappedInvoke(Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
       в System.Windows.Threading.DispatcherOperation.InvokeImpl()
       в System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state)
       в System.Threading.ExecutionContext.runTryCode(Object userData)
       в System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
       в System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
       в System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       в System.Windows.Threading.DispatcherOperation.Invoke()
       в System.Windows.Threading.Dispatcher.ProcessQueue()
       в System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       в MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       в MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
       в System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter)
       в System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
       в System.Windows.Threading.Dispatcher.WrappedInvoke(Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
       в System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Boolean isSingleParameter)
       в System.Windows.Threading.Dispatcher.Invoke(DispatcherPriority priority, Delegate method, Object arg)
       в MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
       в MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
       в System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
       в System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
       в System.Windows.Threading.Dispatcher.Run()
       в System.Windows.Application.RunDispatcher(Object ignore)
       в System.Windows.Application.RunInternal(Window window)
       в System.Windows.Application.Run(Window window)
       в System.Windows.Application.Run()
       в D3Test.App.Main() в ....\Мои документы\Visual Studio 2008\Projects\D3Test\D3Test\obj\Debug\App.g.cs:строка 0
       в System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
       в System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       в Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       в System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       в System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       в System.Threading.ThreadHelper.ThreadStart()


Mar 31, 2009 at 9:50 AM
Hi, vpv!

Thank you, we know about this behaviour, and it has been recently changed (fixed) and in next release you'll be able to put ChartPlotter wherever you want)

P.S.: Russian Visual Studio shows funny exception messages)

Mikhail.