Jump to content
Software FX Community

daviddam

Members
  • Posts

    24
  • Joined

  • Last visited

daviddam's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. OK, I tried it out and found 365 looks to be the right value for anyone else that may be interested.
  2. Sorry to open this thread up again, but I was wondering what value to use for yearly? 360? 365? Thanks! Dave
  3. OK, that makes sense. Thank you for the code as well. Dave
  4. Awesome! That's what I was hoping you were going to say. Thanks! Dave
  5. When the chart area (control - legend size) gets small my app crashes. The exception is below. I recently added a timespan to the x-axis of 90 days. If I take out the timespan the chart does not crash, so it appears to have to do with the timespan. System.ArgumentOutOfRangeException: The added or subtracted value results in an un-representable DateTime. Parameter name: months at System.DateTime.AddMonths(Int32 months) at cq.a(Double A_0) at cq.a(Double A_0, Double A_1, Boolean& A_2, Boolean& A_3, Double& A_4) at ChartFX.WPF.Axis.b(bi A_0, as& A_1, b3& A_2, Double A_3, Double A_4, j A_5, Double A_6, Double A_7) at ChartFX.WPF.Axis.a(bi A_0, as& A_1, b3& A_2, Double A_3, Double A_4, j A_5, Double A_6, Double A_7) at ChartFX.WPF.Axis.a(Size A_0, j A_1, FrameworkElement A_2, IPlotArea A_3, cb A_4) at ChartFX.WPF.Axis.a(Object A_0, RenderEventArgs A_1, cb A_2) at ChartFX.WPF.Axis.d.a(Object A_0, RenderEventArgs A_1) at ChartFX.WPF.Internal.RenderEventHandler.Invoke(Object sender, RenderEventArgs e) at cd.a(PaintMark A_0, Double A_1, Double A_2, Boolean A_3, Boolean A_4, RenderEventArgs& A_5) at cd.a(PaintMark A_0, cn A_1, Double A_2, Double A_3, aq[] A_4, LogicalItemCollection A_5, LogicalItemCollection A_6, Int32 A_7) at cd.a(cn A_0, Double A_1, Double A_2) at cd.d(Double A_0, Double A_1) at cd.a(Double A_0, Double A_1, Boolean A_2) at aj.OnRenderSizeChanged(SizeChangedInfo sizeInfo) at System.Windows.ContextLayoutManager.fireSizeChangedEvents() at System.Windows.ContextLayoutManager.UpdateLayout() at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg) at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork() at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
  6. I've been giving this more thought.. How would you force monthly intervals? 30 days is not accurate. Neither is 90 for quarters actually. Is there code in the chart to recognize 90 (or 30) as "special" intervals and work accordingly? Thanks!
  7. doh!, of course. Now don't I feel foolish. Actually, now that I think of it, will this actually produce quarters (Jan-Mar, Apr-Jun, etc.), or just ensure that the intervals are 90 days apart based on the first point? Thanks!
  8. This is probably a really basic question, but here it goes.. We have a chart that we only want quarters displayed on the X-axis. If we shrink the chart "just right" the chart will automatically display quarters, but the request is that only quarters display regardless of the chart size. Is there a setting somewhere that I can set to do this? Thanks! Dave
  9. It is my understanding that in WPF (not just ChartFX) only the thread that creates a UI object can access it. I ran into a similar problem with some other code, and this is the response I received. Unfortunately I can't find a link at the moment that explicitly states this, sorry. You can look at using Control.Dispatcher.Invoke or BeginInvoke to try to get your code working. However, In my case, I ended up doing all of the non-UI calculations in a separate thread and then passing the data to the main thread to get my UI objects created. If I can find the right links, I'll post them. Sorry I couldn't be of more help. I just wanted to let you know that based on my experience with this issue I don't believe ChartFX is the root of the problem and that the WPF is responsible. That isn't to say that ChartFX may not have a workaround for it. Dave
  10. Oh, I thought the %v# was to display additional values required by a point for gallery types like gantt or financial chart types. Or, would this work like that for those too? Thank you again for your prompt replies.
  11. I have found that if I put the %v (Data Value) token into the Format for a tooltip more than once, that I get succesive values from the series. In fact, it will wrap around to the beginning of the series to get values. For example, Let's say my series Data Values are: 2,4,6,8. Let's also say that the series.ToolTips.Format="%v %v %v". If I hover over the first data point the tooltip will say "2 4 6". If I hover over the 3rd data point it will say "6 8 2". Is this expected behavior? If so, is there a way to display a data value more than once in a tooltip? Thanks. I'm using build 0.8.3111.29088.
  12. I am trying to customize the tooltips for a series through code. I am setting the ToolTips.Format property to "%v on %x" but I am seeing the series name on the tooltip when it appears. I have tried other formatting but the series name always appears on the first line of the tooltip. Am I doing something wrong? Thanks! I'm using build 0.8.3111.29088. SeriesAttributes series = new SeriesAttributes();series.ToolTips.Format = cSeries.ToolTips.Format;
  13. I just realized I was using the older version of the DLL. However, the error still occurs in build 0.8.3111.29088.
  14. I recently upgraded to a newer build (0.8.3069.27327), and I now am getting an error when displaying a pie chart. I tracked down the problem to when I am creating the series. Due to the nature of the program, the chart type is not necessarily known so the code is blindly setting the series BindingPath and BindingPathX properties. In previous builds, this did not cause a problem with the pie chart. Obviously, I will add code to handle this situation, but I thought I would share what I have found in case anyone else runs into this problem. I recognize that the BindingPathX is not needed for single-value charts (pie, pyramid, and doughnut), but I don't think the control should blow up if the property is set. System.NullReferenceException: Object reference not set to an instance of an object.<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /> at ChartFX.WPF.Axis.ak() at ChartFX.WPF.Chart.a(Boolean A_0) at ChartFX.WPF.Chart.ax() at ChartFX.WPF.Chart.MeasureOverride(Size constraint) at System.Windows.FrameworkElement.MeasureCore(Size availableSize) at System.Windows.UIElement.Measure(Size availableSize) at System.Windows.ContextLayoutManager.UpdateLayout() at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg) at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork() at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) Some times there is an additional error message that comes up after the first one. If the second one appears, the app goes down. System.NullReferenceException: Object reference not set to an instance of an object. at ChartFX.WPF.Axis.ak() at ChartFX.WPF.Chart.a(Boolean A_0) at ChartFX.WPF.Chart.ax() at ChartFX.WPF.Chart.MeasureOverride(Size constraint) at System.Windows.FrameworkElement.MeasureCore(Size availableSize) at System.Windows.UIElement.Measure(Size availableSize) at System.Windows.ContextLayoutManager.UpdateLayout() at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg) at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork() at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) at System.Windows.Threading.DispatcherOperation.InvokeImpl() at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state) at System.Threading.ExecutionContext.runTryCode(Object userData) at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData) at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Windows.Threading.DispatcherOperation.Invoke() at System.Windows.Threading.Dispatcher.ProcessQueue() at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler) at System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Boolean isSingleParameter) at System.Windows.Threading.Dispatcher.Invoke(DispatcherPriority priority, Delegate method, Object arg) at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam) at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg) at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame) at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame) at System.Windows.Threading.Dispatcher.Run() at System.Windows.Application.RunInternal(Window window) at System.Windows.Application.Run(Window window) at System.Windows.Application.Run() at Desktops.App.Main() at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args) at System.AppDomain.nExecuteAssembly(Assembly assembly, String[] args) at System.Runtime.Hosting.ManifestRunner.Run(Boolean checkAptModel) at System.Runtime.Hosting.ManifestRunner.ExecuteAsAssembly() at System.Runtime.Hosting.ApplicationActivator.CreateInstance(ActivationContext activationContext, String[] activationCustomData) at System.Runtime.Hosting.ApplicationActivator.CreateInstance(ActivationContext activationContext) at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssemblyDebugInZone() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart()
  15. Thank you again for your prompt reply! David
×
×
  • Create New...