The type 'Microsoft.Reporting.WebForms.ReportViewer' exists in both

Bharathi Paulraj 21 Reputation points
2022-08-27T16:34:14.09+00:00

I have one SSRS Report using SOAP in sharepoint.In my viaual studio code it is showing one error.

The type.Microsoft.Reporting.WebForms.IReportServerCredentials.exists.in both c:\Windows\assembly\GAC-MSIL\Microsoft.ReportViewer.WebForms\12.0.0.0-89845dcd8080cc91\Microsoft.Reportviewer.WebForms.DLL and c:\Windows\assembly\GAC-MSIL\Microsoft.ReportViewer.WebForms\10.0.0.0-b03f5f7f11d50a3a\Microsoft.ReportViewer.WebForms.dll"

I tried to add qualifyAssembly node in web.config.But it is not working.Visual studio version is 2015.I am using sharepoint 2016 onpremise.
How to solve it?

Microsoft 365 and Office | SharePoint | Development
{count} votes

1 answer

Sort by: Most helpful
  1. Tong Zhang_MSFT 9,251 Reputation points
    2022-08-29T05:58:43.383+00:00

    Hi @Bharathi Paulraj ,

    According to my research , try to remove one from the web.config file, for example:

    <add namespace="Microsoft.Reporting.WebForms" assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" tagPrefix="Reporting"/>  
    

    Similar issue : https://social.msdn.microsoft.com/Forums/en-US/c46c8efc-c5f9-4785-a9c0-f9946a17db54/the-type-microsoftreportingwebformsreportviewer?forum=aspsqlserverreporting

    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.



Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.