C#WPF D3(动态数据显示)图表项目

时间:2012-12-07 10:47:01

标签: c# wpf charts dynamic-data-display

我正在尝试使用D3。首先我在上个版本下载并通过VS2012打开它。没有做任何改变我尝试运行测试项目,我在运行时收到奇怪的错误消息,详情如下。锄头我可以解决这个问题吗?

System.Security.VerificationException was unhandled by user code
  HResult=-2146233075
  Message=Operation could destabilize the runtime.
  Source=DynamicDataDisplay
  StackTrace:
       at Microsoft.Research.DynamicDataDisplay.Charts.AxisControl`1..ctor()
       at Microsoft.Research.DynamicDataDisplay.Charts.NumericAxisControl..ctor() in c:\Projects\DynamicDataDisplay\Charts\Axes\Numeric\NumericAxisControl.cs:line 10
       at Microsoft.Research.DynamicDataDisplay.Charts.NumericAxis..ctor() in c:\Projects\DynamicDataDisplay\Charts\Axes\Numeric\NumericAxis.cs:line 18
       at Microsoft.Research.DynamicDataDisplay.Charts.HorizontalAxis..ctor() in c:\Projects\DynamicDataDisplay\Charts\Axes\Numeric\HorizontalAxis.cs:line 18
       at Microsoft.Research.DynamicDataDisplay.ChartPlotter..ctor() in c:\Projects\DynamicDataDisplay\ChartPlotter.cs:line 16
       at System.Xaml.Schema.XamlTypeInvoker.DefaultCtorXamlActivator.InvokeDelegate(Action`1 action, Object argument)
       at System.Xaml.Schema.XamlTypeInvoker.DefaultCtorXamlActivator.CallCtorDelegate(XamlTypeInvoker type)
       at System.Xaml.Schema.XamlTypeInvoker.DefaultCtorXamlActivator.CreateInstance(XamlTypeInvoker type)
       at System.Xaml.Schema.XamlTypeInvoker.CreateInstance(Object[] arguments)
       at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateInstanceWithCtor(XamlType xamlType, Object[] args)
       at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CreateInstance(XamlType xamlType, Object[] args)
  InnerException:

1 个答案:

答案 0 :(得分:1)

自己的问题和自己的解决方案:)我解决了我的问题。问题是库和测试项目构建目标平台的不一致。当我将测试项目构建目标平台从x86更改为任何cpu时,问题就解决了。我还是不明白VS2012的错误信息意思:)但无论如何问题都解决了。