Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Errors Trying to Generate Reports Outside of VStudio IDE

As I reported here, I was able to successfully use my VS2008 Crystal Reports templates when I upgraded my project to VS2012.

However, while everything works fine within the VS2012 IDE, I'm not having the same good fortune when running my app standalone with IIS7.0.  The error message is quite complex so I copied it into a Word document which you can view here.

The deployed server is running Window 7 Ultimate (64-bit) with SP1 installed.  So naturally I assumed that I should install the Crystal Reports 64-bit Merge Module for VS2010 (Version 13.0.4), which is what I've done.

I'm hoping that someone else has experienced the same problem when they deployed their app and can guide me to what I've done wrong.

Thank you,

Robert

replied

An hour later . . .

I finally figured out what the problem was.  Hopefully this will help others too!

I actually have VS2012 installed on two computers, side-by-side:

  1. My laptop
  2. My main workstation, an i5 desktop with two large monitors

They're configured slightly differently, allowing me to test different aspects of my application.  Normally I do most of my work on the workstation.  Sometimes though, when I want to try out a new approach for something, I just quickly copy over my latest code to my laptop and work on the new idea there.  That way, if it doesn't prove itself I don't have to restore any code on my workstation.

Both of these computers publish the latest compiled code to my test server, which is nearby.

Last night, I definitely had the compiled version of my app working properly with Crystal Reports.  That version was published from my laptop.  After I had tested the reports, I copied the latest code back to my workstation and kept on working on other things.  I eventually published a newer version of the application from my workstation.  When I did this, I neglected to retest the reports.  This morning, when my QA person logged into my test server and ran the reports, they failed - with the aforementioned infamous "...1304" error.  But why?

I finally found the answer by looking in the C:\Windows\assembly folder on both of my development machines.  The version numbers of CrystalDecisions.CrystalReports.Engine were different:

  • Laptop: 13.0.2000.0
  • Workstation: 10.5.3700.0

As soon as I saw this difference I performed the obvious test:

  • When the app is published from my laptop to the test server . . . the reports work!
  • But when it's published from my workstation they fail. :-(


The workstation is about a year older than the laptop.  Looking at the installed programs, I discovered the following:

  • Laptop: SAP Crystal Reports runtime engine for .NET Framework 4 (64-bit)
  • Workstation: Crystal Reports Basic Runtime for Visual Studio 2008 (x64)

A further note:

In my particular case, there is no reference to Crystal Reports in my web.config file.  So I got to wondering how the test server could be running properly with one compiled version and yet failing with another.  The answer came by using a Hex Editor (or Notepad) to examine my Website.dll file.  Sure enough, the version number of a file called "CrystalDecisions.Shared" is embedded in there.  That's where the conflict lay and that's why it wouldn't run when published from my workstation.

So now I'm going to uninstall the older Crystal Reports Basic Runtime and install the latest SAP Crystal Reports runtime engine.

It's nice when clarity replaces confusion!  Hopefully my frustration will help out someone else in the future.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question