Skip to Content
author's profile photo Former Member
Former Member

Error after upgrading to SP3

I had the following code and it was working using the standard install of Crystal Reports 2008.

' pCrystalReport is a passed in CrystalDecisions.CrystalReports.Engine.ReportDocument object
Dim objDatabaseTable As CrystalDecisions.CrystalReports.Engine.Table

For Each objDatabaseTable In pCrystalReport.Database.Tables
       ' SetDatabaseTableLogOn for table
Next objDatabaseTable

After running the SP3 update it errors on the For Each line of code with:

Unable to cast object of type 'CrystalDecisions.CrystalReports.Engine.Table' to type 'CrystalDecisions.CrystalReports.Engine.Table'.

Is this a known issue?

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Oct 25, 2010 at 08:50 PM

    I found the issue and thought I would share what was...

    The report being passed in was coming from another dll. The next time I opened that project I got prompted to upgrade my version of Crystal 2008. I recompiled it, then opened my main project again. Now I got a message that the versions of the Crystal dll's in the 2 projects were incompatible. I manually changed the references in the main project to match the upgraded one and everything is working now.

    The part I found odd was I never got the prompt to upgrade my main project.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.