C# vs 2008 crystal reports exception on client machine - c#

my client machine is 64 bit but the application i build is in x86 target platform in C# Visual studio 2008 with win7 32 bit. Now the problem is when i click crystal report button on my application it gives me this error. It works perfectly fine on development machine but on client i just see this message box again and again.
"An error has occurred while attempting to load the Crystal Reports runtime.
Either the Crystal Reports registry key permissions are insufficient or the Crystal Reports runtime is not installed correctly."
I have checked crystal reports even in prerequisites just like the attached picture
Also i have installed manually crystal reports runtime from http://downloads.businessobjects.com/akdlm/cr4vs2010/CRforVS_redist_install_32bit_13_0.zip
But error seems not leaving my life at all.
I am using first time crystal reports in C# but it gave me very hard time just to install it on the client machine. I have googled and found solutions most of them i have tried like setting prerequisites and changing mode from Any CPU to x86 but none has fix my error.

IIRC I've had a similar problem in the past caused by deploying Crystal with the Setup package. Have you tried uninstalling Crystal Runtime from the target machine and installing the correct (64-bit) runtime version onto it directly?
You can leave your target CPU as Any.

I found the answer what i did is i have opend the directory in my development machine C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bootstrapper\Packages\CrystalReports10_5 and copied the runtime exe for crystal reports and than i have ran it manually on the client machine. By doing this my client machine is now able to run crystal reports perfectly fine. I believe i should store this crystal report runtimes in my setup program for other clients.

Your application is targeting x86 version and you are installing in 64 bit machine,right?
I think crpt x64 installer is corrupted.
After making installer,go to debug folder and find crystal report folder.You can see two crpt installer,one is x86 and another is x64. Delete x64 installer. copy x86 to another place and rename it as x64.Then recopy to crpt folder.Now check installation.
I think I can make you understand.

Related

Successfully run a C# project on client machine with proper functioning Crystal Reports?

I made my project in C# Visual Studio 2017 using .Net Framework 4.7 and SQL Server 2008. Now I tried to run my project in the client machine which has Windows 10 installed on it. After installing I ran the .exe file, all my functions are running smoothly except my Crystal Reports Viewer.
You need to install SAP runtime for Crystal reports on the client machine
You should have install SQL server on your client machine to make the database working similarly you are required to download the client tool for SAP report. So instal Crystal Report Runtime for client machine and it will let you open your reports on your client machine without any error.
Thanks everyone for your answers but I solved it , the issue was in version of Crystal report as it needed CR V13.0.25.134 for 64 bit but I was using CR V13.0.26 , so yeah I made it through. Thanks again everyone for your time.

Crystal Report Deployment

I have a VB.Net winforms application that it includes all the DLL in its BIN folder, i deploy it to the client's server everything works good without installing anything on each workstation.. i take a shortcut from the server..
the problem is when i try from any station to preview a crystal report file even tho i installed the runtimes on the server where the shortcut is located but it doesnt work without installing the runtime on each workstation
Any idea how to reference or load crystal report runtime from where the shortcut is located?

The document has not been opened - Crystal report

I have some crystal reports on a website. They are working fine on my local machine. I'm using Crystal Reports version 13.0.3500.0
The test environment it is on another server, Windows 2008 R2, 64 bit operating system.
The problem is that when on the test environment I want to use a crsytal report, I get the following error: The document has not been opened
I spent some time already to figure it out what can be the problem, but without any success. I'm using the same DLL-s as in my local machine.
I checked and the folder where I have the report has all the rights.
Can you please advise?
if you are using IIS go to the application pool select your web site Click on Advanced Settings on the right side Set 'enable 32-bit application ' true (crystal report runtime engine for .net 32-bit had to be installed)
I was getting this error before I installed Crystal Reports Runtime (21) on my server.
Here is an article where you can find download links etc.

Crystal Report Load error with Local IIS

I am trying to use Crystal Reports in my new web application.
I allready used it in an older project (VS 2008) and works great.
Now I want to use it in my new web application with Visual Studio 2015.
I installed Crystal report from http://scn.sap.com/docs/DOC-7824 , version 'v.13.0.15.1840'
And in my project I installed the Crystal.Report.Essentials from the Nuget Manager.
My code looks like this:
ReportDocument rptEHBOFiche = new ReportDocument();
rptEHBOFiche.Load("C:\\TEMP\\InputFiche.rpt");
Everytime I get the error that the loading of the report had failed.
I tried other paths but nothing is working.
Does anyone has a solution?
EDIT:
I found the problem, but not the solution.
The problem is this doesn't work if my project is on Local ISS. If it's on ISS Express I have no problem..
I have set the app pool to enable 32 bit applications too.
Can you try the following code?
if File.Exists ("C:\\TEMP\\InputFiche.rpt")
rptEHBOFiche.Load("C:\\TEMP\\InputFiche.rpt");
else
throw new Exception ("wrong path");
EDIT 2 Answer
In http://scn.sap.com/docs/DOC-7824 , "Install executable" is Crystal Reports Visual Studio integration. "MSI 64 bit" is IIS Runtime.
Install MSI 64 bit to have your IIS working. Don't lose your time on 32 bit apps, 64 bit work great.
I found the solution:
I needed to give my App Pool full rights to the c:\Windows\Temp folder

Crystal Reports in ClickOnce deployment

My application needs to print a Crystal Reports report. It does not show a preview, just takes two parameters and shows a print dialog to set the printer. It works fine on computers that have Crystal Reports installed, but I do not have a way to enforce clients have it already installed.
I have read in various places that adding the ClickOnce prerequisite "SAP Crystal Reports Runtime Engine for .NET Framework" would allow the required Crystal Reports libraries to be registered on the client. When installing the application on the client, it does download the runtime, and installs the runtime, but the application fails to install stating that various CrystalDecisions and CrystalReports assemblies must be registered in GAC.
The first is CrystalDecisions.ReportAppServer.CommonObjectModel. If I add a reference to this in the project and redeploy, then it just gives another message about another assembly. I literally did this 15 times, and never got a seamless install.
What am I missing? I followed this guide from the SAP website (zipped, 2.2 MB, contains a Microsoft Compiled HTML Help file, crnet_dg_2010_en.chm).
I had this problem: for Click-Once applications, you must download and install the 32-bit version of the Crystal Reports Runtime on the client regardless of the client computer's architecture. I ended up installing both the 32-bit and the 64-bit using the MSIs provided on SAP's site to cover all bases and make the GAC error to go away. Afterwards, everything ran smoothly.
Download and install the MSIs (not the executable) from here
FOR CLICK ONCE DEPLOYMENT
In addition to making SAP Crystal Reports Runtime a prerequisite, you need to modify the product.xml file on the development machine. This file is located in: {Program Files}\Microsoft SDKs\Windows\v*.0A\Bootstrapper\Packages\Crystal Reports for .NET Framework 4.0\
Find the following line and comment it out:
<BypassIf Property="ProcessorArchitecture" Compare="ValueNotEqualTo" Value="Intel"/>
Now, re-publish your solution and the setup should install both runtimes on 64-bit machines.
If the above solution didn't work try this,
Go into your project Properties.
Go to the Publish tab.
Click the Application Files button.
Change Publish Status from Prerequisites(auto) to Exclude any file with CrystalDecisions or BusinessObjects in the name.
Click OK
Rebuild your application, then republish it to your site or file share to be installed by your clients.
I found it in this location:
C:\Program Files (x86)\SAP BusinessObjects\BootStrapper\Packages\Crystal Reports for .NET Framework 4.0
C:\Program Files (x86)\Microsoft Visual Studio 14.0\SDK\Bootstrapper\Packages

Categories