What is current version of ReportViewer supported by WinHost?

Discussion in 'Site Programming, Development and Design' started by John Dee, Dec 28, 2015.

Tags:
  1. Today is 28-Dec-2015 -- what version of ReportViewer is active in WinHost?
    I am coding in ASP.NET 4.5.1 and using VS-2012 with ReportViewer version 11.
    Is this supported by WinHost now?

    Do you know which files supporting ReportViewer need to be uploaded into my site's \bin folder ?
    Thanks.
     
  2. CORRECTION...my current local ReportViewer version is 12 not 11. Sorry.
     
  3. ComputerMan

    ComputerMan Winhost Staff

    Do you have the report viewer working locally in your project in Visual Studio?

    If so try redeploying your application to our servers but this time make sure you use the option "Copy Local to True" within your Visual Studio project.

    This will make sure your dll files that the report viewer is using gets deployed to the site when you use web deploy.

    https://msdn.microsoft.com/en-us/library/t1zz5y8c(v=vs.90).aspx
    http://stackoverflow.com/questions/...y-local-be-set-to-true-and-when-should-it-not
     
  4. I have been asked to reply answers to the following four questions regarding getting ReportViewer functionality from my local computer VS-2012-Express website to Winhost.
    1. Did you use a Project in VS or a Web site? My local computer coding solution is a website.
    2. What error message are you getting on your site?
    Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
    Exception Details: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=12.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified.
    Source Error:
    Line 14: <div>
    Line 15:
    Line 16: <rsweb:ReportViewer ID="ReportViewer2" runat="server"
    Line 17: Font-Names="Verdana" Font-Size="8pt"
    Line 18: WaitMessageFont-Names="Verdana" WaitMessageFont-Size="14pt"

    3. Does your report run locally in your environment when you test it? Yes.
    4. Does your Visual Studio give you the option to FTP your site to our server? VS-2012-Express offers a "Copy Web Site..." option under the WEBSITE menu option. I have NOT tried this since I do not want the entire set of folders and excluded files and other files put to a production (or in this case, to my deployed testing-bed on WinHost).
    PLUS -- this option does not encrypt the password to the WinHost ftp site.
    I use FileZilla to upload changed source-code to WinHost.
     
  5. ComputerMan

    ComputerMan Winhost Staff

    That's the problem. You need to allow Visual Studio to upload the files for you because it place the files in the correct spot . You might not be uploading the correct files or you might not be placing them in the correct spot. Try using Visual Studio to upload the web site files for you and see if that resolves the issue.
     
  6. Thank you for your guidance. I have solved the problem -- once I found the ReportViewer 11 package at : https://www.nuget.org/packages/MicosoftReportViewerWebForms_v11/
    I then had to "clear-out" references to the RV v12 in my web.config and within my source code.
    I un-installed any RV and RB v12 from Windows Programs control panel.
    I started VS-2012-Express and used NuGet as instructed in the link to install the ReportViewer on my local computer and solution/project.
    The Web.config file also was updated with the correct v11 information.
    This did the trick.
    I then copied the Microsoft.ReportViewer.WebForms.dll into my project's \bin folder.
    I edited my "page" needing the ReportViewer and the following declaration was added to the page:
    <%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=11.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
    I tested locally and all was OK...then using FileZilla, I uploaded the revised page.aspx and the \bin folder contents (deleting bad references from WinHost>site\bin).
    Then SUCCESS -- WinHost shows the report on my report-page just as if locally.
    Your assistance is very welcome and, again, thank you....John
     
    ComputerMan and Michael like this.

Share This Page