Could not load file or assembly Microsoft.ReportViewer.WebForms or one of its dependencies
Asked Answered
W

5

9

When I goto my site I get this error...

Error   101 Could not load file or assembly 'Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. C:\mlui\csharp\WebAdmin_solution\WebAdmin\web.config    209

which is this line of code:

<add assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />

I am using Visual Studio 2012, do I need to download something and add it to the VS 2012 folder?

Wharfage answered 13/2, 2013 at 15:59 Comment(0)
J
6

If you're actually using the Reporting Services, try to install the Reporting Services redistributable on the server you deploy your web site to or include the required assemblies with your web application.

Jackstay answered 13/2, 2013 at 16:6 Comment(4)
Do you have a link where I can download it?Wharfage
How would I include the required assembiles to my web application?Wharfage
It should be on your development machine already, but you can try this: microsoft.com/en-us/download/details.aspx?id=3841Jackstay
Well, there must be a reference to the assemblies in your project - can you set the "Local copy" property to true in the reference's properties? Then the DLLs should be copied to the output folder. At least this is the case for desktop projects...Jackstay
S
4

Right Click on the Project and open and go to Manage NuGet Package

Under browse tap search for Microsoft.Reporting.WebForms

select Microsoft.ReportView.Webforms

enter image description here

and click install.

  • so it will take care of respective dependency and so on,
Sartain answered 28/2, 2020 at 10:51 Comment(0)
T
3

Look at your folder instalation, what version have the folder ReportViewer. And put Version=X.0.0.0 where X means the version of your instalation.

In my case, I have

Instalation Folders

But only inside 10.0 I have the ReportViewer

ReportViewer Folder

And my web.xml is like this

<assemblies>
                <add assembly="Microsoft.ReportViewer.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
                <add assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
                <add assembly="Microsoft.ReportViewer.WinForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
      </assemblies>
    <buildProviders>
                <add extension=".rdlc" type="Microsoft.Reporting.RdlBuildProvider, Microsoft.ReportViewer.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
            </buildProviders>
Tippets answered 13/11, 2013 at 11:32 Comment(1)
thanks guys.. i've got the idea that maybe there is no installed reportviewer in that server.. so i download a separate installer for reportviewer for vs2010.. and it works!!Joyann
D
2

try to update it with latest assembly of version 10.0 by add reference to your project and build it again after adding assembly file will looks something like below

Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
Discordancy answered 13/2, 2013 at 16:2 Comment(0)
H
-1

Just Search Microsoft report viewer in internet you will get exe file , install it, Issue will resolved

Hallvard answered 13/12, 2022 at 19:20 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.