Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1512
  • Last Modified:

Visual Basic.Net 2008 - Cannot Run Crystal Reports Viewer

We have an application that we migrated from Visual Basic 6.0 to Visual Studio.Net 2008 Professional using the migration wizard.  The app contains 540 forms.  We used Component One's True DBGrid 8.0 in the VB6 app, but the migration tool did not migrate those grids.  The migration wizard replaced them all with empty, unformatted, unbound VB.Net data grids.  So we had to delete the unformatted data grids and rebuild 98 True DB grids in the app.  The app uses SQL Server 2005 for stored databases and a mixture of SQL Server and MS Access tables as the underlying table for grids and as the input tables for Crystal Reports.

The problem we are having at the moment is as follows:  If we open the app and go to an application function that uses the Crystal Report Viewer - like a simple 20-line table listing - the report is generated in a reasonable period of time considering that it is the first time the report (or any report) was generated in this session.  If we press the printer icon to print the report, printer selection is very slow to pop up and the printing of the one page report is also very slow.  If we then go back and request the same report again, the report takes longer to generate and printing (if it works) is even slower than it was on the first request.  Screen painting of the menu screen is normally very fast, but is now very slow and fragmented.  If we try a third time, we never even get to request the report.  the app hangs as soon as we click on the menu icon to open the screen.

The same thing happens if we try to switch from one Crystal Report request to another while in the same session.  We end up having to reboot the PC to get it back up and running.  There is no way to cancel the task (task manager is non-responsive).

The CPU utilization is always at 100% as soon as the app is started and remains at 100% throughout the session.

We also tried the same app under VS.Net 2005 - similar results.

We are now using Crystal Reports 2008.  We have had the exact same problem with CR 10, XI, and X1 R2.

We are running VS.Net 2008 Professional with the SP1 Beta installed and MS.Net Framework 3.5 with SP1 Beta installed as well.

The reports are generated and printed quickly and correctly directly from CR 2008 - the problems only occur when generated from the VB app.

The app works perfectly under VB6/SQL Server 2000 and CR 10.

Any thoughts or suggestions on how to make the Crystal Viewer work properly and repeatedly?
0
portdata
Asked:
portdata
  • 6
  • 5
2 Solutions
 
Bob LearnedCommented:
First things first, migrating from VB6 is problematic at best.  Secondly, it often leaves projects in a unusable state for a long time, cleaning up the mess it makes.  Sometimes, if you take a step back and look at it, the .NET way would be better, but it takes time to learn that way.  

Are these simple reports, or complex?  What happens if you create a new .NET project, and just try implementing the report viewer, without all the other noise involved in the solution?
0
 
portdataAuthor Commented:
Thanks for the reply.

I created a new project last night with only a simple menu form and two simple Crystal Reports apps forms - they both just select a few records from a SQL database, create an MS Access data source for the Crystal Report and invoke the Crystal Reports Viewer.

The first time the report is generated reasonably quickly.  Printing is sluggish (only one page to print) but it works.  I then clicked on the other item (a second one page report shoudl be displayed) and it just hangs.  The CPU utilization is at 100%.  I cannot run task manager.  I cannot do anything at all.  My computer (a Dual Core Del Optiplex with 2.66 GHz processors and 2 GB or RAM) running nothing else is dead in the water.  I have to power off the PC to get it restarted.  This PC is running Windows XP Pro.

I can always get it to produce a Crystal Report once, but never second one.  It behaves like there is a serious memory leak or that the first execution never really finishes.

Even the video displays get messed up - screen display becomes very slow and fragmented as well after the first Crystal invocation.

My next test for today is to install the app on one of our Vista Ultimate machines to see if anything changes.
0
 
Bob LearnedCommented:
Are you using Crystal Reports that you purchased, and not the version that comes with Visual Studio.NET?
0
Transaction-level recovery for Oracle database

Veeam Explore for Oracle delivers low RTOs and RPOs with agentless transaction log backup and transaction-level recovery of Oracle databases. You can restore the database to a precise point in time, even to a specific transaction.

 
portdataAuthor Commented:
Yes - a purchased version
0
 
Bob LearnedCommented:
Ok, I haven't used the Crystal Reports outside of the IDE, so I can't really comment on what is happening, but as often happens with Crystal Reports, it sounds like a pretty serious bug.
0
 
portdataAuthor Commented:
I was just looking to see how to choose the Crystal Reports Basic that comes with the IDE.  Do you happen to  know how to choose that one?
0
 
Bob LearnedCommented:
If you already have a report defined, you can double click on it, in the Solution Explorer, and it should open the report in the IDE.  You will more than likely have to register the software before you can run it.
0
 
portdataAuthor Commented:
Since I already have Crystal Reports 10, XI R2  and 2008 installed on my PC, it opens without any problem.  But when I try to run it more than once, it hangs.

I tried deleting all Crystal Reports references and then added an existing report to the solution explorer.  It automatically added Crystal Reports references, but it picked a few from 2008 and a few from XI R2, but the .Net 1.0 version, not 2.0.

I am really getting to hate this problem.

I am going to try installing the Crystal Reports Basic that is bundled with VS.Net 2008 and see if that makes any difference.
0
 
mlmccCommented:
Are you closing the reports?

Are you cleaning up the viewer and the report objects?

mlmcc
0
 
Bob LearnedCommented:
>>We are running VS.Net 2008 Professional with the SP1 Beta installed and MS.Net Framework 3.5 with SP1 Beta installed as well
There is no telling what impact installing Betas has on the situation.
0
 
portdataAuthor Commented:
To answer mimcc:

No, all we are doing is invoking the report viewer to generate the report.
I will have to find out what commands I need to do the cleanup you suggest.
I am really lousy and careless about object cleanup.

portdata
0
 
portdataAuthor Commented:
Thanks to both TheLearnedOne and mimcc for your time and effort.  The problem appears to be a problem with my Windows XP development machine, or the installation of VS.Net 2008 on that machine, but your thoughts are what inspired me to try the app on my Vista notebook, and that's worth 500 points any day!
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

  • 6
  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now