What requirements do I need to run a C # program on a client machine?

1

I'm testing my application in c# on the client machine, it works normally, my problem is only in printing the reports, when printing this generate this error:

Ocorreu uma exceção sem tratamento no aplicativo. Se você clicar em
continuar, o aplicativo ignorá esse erro e tentara continuar. S e Clicar
em Encerrar, o aplicativo será incerrado imediatamente.

Não foi possivel carregar arquivo ou assembly
"Microsoft.ReportViewer.WinForms, Version=11.0.0.0 Culture=neutral.
PublicKey Token=89845dcd8080cc91" ou uma de suas dependências.
O sistema não pode encontrar o arquivo especificado.

Before I ran my application, I installed the following software on the client machine:

  • Sql_server 2008 R2;
  • ReportViewer 2008;
  • NET.Framework_3.5_Windows_8.1;
  • VisualBasicPowerPacksSetup;

But he still does not issue the report.

    
asked by anonymous 02.08.2017 / 11:21

2 answers

1

try this:

In the "Copy Local" option mark as true, and compile the project

    
02.08.2017 / 13:42
0

As you said you installed Microsoft Report Viewer Redistributable 2008 then you just need to copy the following DLLs to the Bin of your application:

• Microsoft.ReportViewer.Common.dll
• Microsoft.ReportViewer.DataVisualization.dll
• Microsoft.ReportViewer.ProcessingObjectModel.dll
• Microsoft.ReportViewer.WebForms.dll
• Microsoft.SqlServer.Types.dll

GAC Path

  

Microsoft.ReportViewer.Common.dll

C:\Windows\assembly\GAC_MSIL\Microsoft.ReportViewer.Common.0.0.0__89845dcd8080cc91
  

Microsoft.ReportViewer.DataVisualization.dll

C:\Windows\assembly\GAC_MSIL\Microsoft.ReportViewer.DataVisualization.0.0.0__89845dcd8080cc91
  

Microsoft.ReportViewer.ProcessingObjectModel.dll

C:\Windows\assembly\GAC_MSIL\Microsoft.ReportViewer.ProcessingObjectModel.0.0.0__89845dcd8080cc91
  

Microsoft.ReportViewer.WebForms.dll

03.08.2017 / 00:21