我安装了VS2017并运行我的应用程序(.net 3.5)。但是当我调用报表的setDataSource时出现错误
这是我的代码:
DataTable data = new RateFactorBO().EstimateActualHour();
if (data.Rows.Count > 0)
{
string _reportname = "~/Reports/EstimateActualHrsRep.rpt";
report.Load(Server.MapPath(_reportname));
report.SetDataSource(data);
}
这是错误:
Additional information: Could not load file or assembly 'file:///C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet1\crdb_adoplus.dll' or one of its dependencies. The system cannot find the file specified.
注意:我安装了CRforVS_13_0_24并尝试在web.config中添加启动,但是它仍然无法正常工作:
<startup useLegacyV2RuntimeActivationPolicy="true"><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/></startup>
有人可以建议我做什么吗?