C# 页面将不会加载,我会得到一个";“Newtown.json”;警告信息

C# 页面将不会加载,我会得到一个";“Newtown.json”;警告信息,c#,charts,chart.js,C#,Charts,Chart.js,我正在将带有样式(线型图)的折线图添加到我的项目中,当我运行它时,页面不会加载。我只得到了加载光标的图像。在visual studio 2019中,我收到以下警告消息: "Found conflicts between versions of "Newtonsoft.Json" that could not be resolved. These references are listed in the build log when log verbosity is set to detai

我正在将带有样式(线型图)的折线图添加到我的项目中,当我运行它时,页面不会加载。我只得到了加载光标的图像。在visual studio 2019中,我收到以下警告消息:

   "Found conflicts between versions of "Newtonsoft.Json" that could not be resolved. These references are listed in the build log when log verbosity is set to detailed. 
有人知道我为什么会得到这个吗?我有newtown.json的最新版本

在我的PackageConfig中,我使用最新的Newtonsoft.json将其设置为这样

<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="Microsoft.Azure.WebJobs" version="1.0.1" targetFramework="net452" />
  <package id="Microsoft.Azure.WebJobs.Core" version="1.0.1" targetFramework="net452" />
  <package id="Microsoft.Data.Edm" version="5.6.0" targetFramework="net452" />
  <package id="Microsoft.Data.OData" version="5.6.0" targetFramework="net452" />
  <package id="Microsoft.Data.Services.Client" version="5.6.0" targetFramework="net452" />
  <package id="Microsoft.Web.WebJobs.Publish" version="2.0.0" targetFramework="net452" />
  <package id="Microsoft.WindowsAzure.ConfigurationManager" version="2.0.3" targetFramework="net452" />
  <package id="MSBuild.Microsoft.VisualStudio.Web.targets" version="14.0.0.3" targetFramework="net452" />
  <package id="Newtonsoft.Json" version="6.0.4" targetFramework="net452" />
  <package id="System.Spatial" version="5.6.0" targetFramework="net452" />
  <package id="WindowsAzure.Storage" version="4.2.1" targetFramework="net452" />
</packages>
这是我在html中设置它的方式:

  <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="line_chart" height="150"></canvas>
    </div>
    <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="bar_chart" height="150"></canvas>
    </div>
    <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="line_styles_Chart" height="150"></canvas>
    </div>

每月费用

每月费用

每月费用


所有引用都是旧的,我认为最好去nuget包管理器更新引用,例如,您使用的是Json.NET的6.0.4版本,最新版本是12.0.2


其中一个依赖项可能需要特定版本的Newtonsoft。您的应用程序使用的是5年前的6.0.4…@DavidG是否有办法将其升级到当前版本?我将在NuGet package manager中梳理您的软件包的依赖关系,并确定Newtonsoft版本之间的差异,并将您对Newtonsoft的直接依赖关系与其他软件包的依赖关系版本标准化
  <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="line_chart" height="150"></canvas>
    </div>
    <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="bar_chart" height="150"></canvas>
    </div>
    <div class="report-card">
        <p class="text-center p-t-20 text-muted">Monthly expenses</p>
        <canvas id="line_styles_Chart" height="150"></canvas>
    </div>