Tiếp theo cài đặt một sạch, dự án của tôi không biên dịch vì tham chiếu đến các dll bị hỏng, vì vậy tôi đã xóa nó và thêm vào nó một lần nữa, sau đó trang web nơi ReportViewer được sử dụng đã đưa ra một lỗi phân tích cú pháp:
The base class includes the field 'rprtReportsViewer', but its type (Microsoft.Reporting.WebForms.ReportViewer) is not compatible with the type of control (Microsoft.Reporting.WebForms.ReportViewer).
tôi tìm thấy một tài liệu tham khảo trên trang web với số phiên bản khác nhau để người tôi vừa nói thêm:
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
tôi đã thay đổi phiên bản 9.0.0.0, và lần này có một lỗi biên dịch khi tôi làm mới trang:
CS0433: The type 'Microsoft.Reporting.WebForms.ReportViewer' exists in both 'c:\Windows\assembly\GAC_MSIL\Microsoft.ReportViewer.WebForms\8.0.0.0__b03f5f7f11d50a3a\Microsoft.ReportViewer.WebForms.dll' and 'c:\Windows\assembly\GAC_MSIL\Microsoft.ReportViewer.WebForms\9.0.0.0__b03f5f7f11d50a3a\Microsoft.ReportViewer.WebForms.dll'
Sau đó, tôi tìm kiếm giải pháp cho "Microsoft.ReportViewer" và tìm thấy nhiều tham chiếu hơn trong quá trình biên dịch.cấu hình:
<add assembly="Microsoft.ReportViewer.WebForms, Version=8.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
<add assembly="Microsoft.ReportViewer.Common, Version=8.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
</assemblies>
<buildProviders>
<add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.Common, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</buildProviders>
Tôi đã thay đổi số phiên bản ở đây quá và nó dừng lại các lỗi
nhưng hãy cho tôi biết một điều về cách bạn xóa tài liệu tham khảo khỏi ứng dụng asp.net? –