Quantcast
Channel: Crystal Reports
Viewing all articles
Browse latest Browse all 1507

Crystal Reports - Issue Upgrading from Server 2003, .NET 2.0 to Server 20012, .NET 4.5

$
0
0

Hello,

If anyone can suggest a better forum this question please let me know.  I have been tasked with moving an asp.net website from an old Server 2003 .NET 2.0 machine to a Sever 2012 R2 machine with IIS 8.5 and .NET4.5.   Everything in our site is working accept for the pages that consume the crystal reports.   When I try to run a page that accesses the crystal report it just crashes the applicaton and on the browser I get the error "The connection to mccoy2 was interrupted."  When I try to run it through Visual Studio 2012, I can't even step through the code. 

On Server 2012, I have

Crystal Reports Redist 2005 x65, Crystal Reports 10.0.0.63327, Crystal Reports 2005 Redist x86,  Crystal Report Redist 2005 x64, Crystal Reports, Basic Runtime for Visual Studio 2008 (x64), SAP Crystal Reports runtime engine for .NET Framework (32-bit), SAP Crystal Reports runtime engine for .NET Framework (64-bit) 13.0.8.1216, and SAP Crystal Reports 13.0.8.1216, version for Microsoft Visual Studio 13.0.8.1216.

When I run the report from the Crystal Reports 10 on the web server it works.  I have considered that maybe I am running into a 32bit/64bit issue so I go into IIS 8.5 and in the application pool I enable 32-bit applications it still bombs.

Interestingly, when I build a report in Visual Studio 2012, and deploy a test website to use it, it works.

When I try to debug in Visual Studio 2012 on the web server the virtual host just crashes.  It there a different DLL or application I need to install?  Is there some odd permission that needs to be enabled on the web server?  Is there a better way to diagnose this problem?

The legacy code looks like this:

Imports

CrystalDecisions.CrystalReports.Engine

Imports

CrystalDecisions.Shared

Imports

CrystalDecisions.Enterprise


Partial

Classhr_EmergencyPhoneList

   

Inherits System.Web.UI.Page

#Region

" Web Form Designer Generated Code "

   

'This call is required by the Web Form Designer.

    <System.Diagnostics.

DebuggerStepThrough()>PrivateSub InitializeComponent()

       

Me.RepDoc = New CrystalDecisions.CrystalReports.Engine.ReportDocument

       

Me.RepDoc.EnterpriseLogonInfo.AuthenticationType = "secEnterprise"

       

Me.RepDoc.EnterpriseLogonInfo.CmsServer = "kildare"

       

Me.RepDoc.EnterpriseLogonInfo.Password = "2000greenroad"

       

Me.RepDoc.EnterpriseLogonInfo.Username = "webconcurrent"

       

Me.RepDoc.UriIsUserEditable = False

   

EndSub

   

ProtectedWithEvents RepDoc As CrystalDecisions.CrystalReports.Engine.ReportDocument

   

'NOTE: The following placeholder declaration is required by the Web Form Designer.

   

'Do not delete or move it.

   

Private designerPlaceholderDeclaration As System.Object

   

PrivateSub Page_Init(ByVal sender As System.Object,ByVal e As System.EventArgs)HandlesMyBase.Init

       

'CODEGEN: This method call is required by the Web Form Designer

       

'Do not modify it using the code editor.

        InitializeComponent()

 

   

EndSub

#End

Region

   

PrivateSub Page_Load(ByVal sender As System.Object,ByVal e As System.EventArgs)HandlesMyBase.Load

       

'Put user code to initialize the page here

       

Dim crDatabase AsDatabase

       

Dim crTables AsTables

       

Dim crTable AsTable

       

Dim crTableLogOnInfo AsTableLogOnInfo

       

Dim crConnectionInfo AsConnectionInfo

       

Dim PFDef AsParameterFieldDefinition

       

Dim ParameterValues AsParameterValues

       

Dim ParameterDiscreteValue AsParameterDiscreteValue

       

Dim DestOptions AsNewDiskFileDestinationOptions

       

Dim ExportOptions AsNewExportOptions

       

Dim ExportRequestContext AsNewExportRequestContext

       

'Dim IOSTream As System.IO.Stream

       

Dim FileName, FileNameVirtual AsString

       

Dim CurrentDateTime AsDateTime

       

Dim mySessionMgr AsSessionMgr = NewSessionMgr

       

Dim myEnterpriseSession AsEnterpriseSession

       

Dim myInfoStore AsInfoStore

       

Dim myEnterpriseService AsEnterpriseService

       

Dim myInfoObjects AsInfoObjects

       

Dim ReportID AsString

       

Dim query AsString = "Select SI_NAME, SI_ID, SI_DESCRIPTION, SI_UPDATE_TS, "& _

           

"SI_PARENT_FOLDER From CI_INFOOBJECTS Where "& _

           

"SI_PROGID='CrystalEnterprise.Report'"& _

            

"And SI_NAME = 'Emergency Call System'"

       

' get report ID from report name

       

Try

'Response.Write("Hello.")

            myEnterpriseSession = mySessionMgr.Logon(

"service_ce", _

           

"password, _

           

"server", _

           

"enterprise")

           

'Response.Write("cluster:" & myEnterpriseSession.ClusterName)

           

'Response.End()

 

           myEnterpriseService = myEnterpriseSession.GetService(

"InfoStore")

          

   myInfoStore =

NewInfoStore(myEnterpriseService)

   Response.Write(

"After infostore")

           myInfoObjects = myInfoStore.Query(query)

          

'myInfoObject = myInfoObjects

           ReportID = myInfoObjects(1).ID

           Response.Write(

"HI")

   RepDoc.FileName =

"ceis://@crystal.site.COM/#"& myInfoObjects(1).ID

Response.Write(

"After file name")

   Response.Write(RepDoc.FileName)

          

'Response.End()


Viewing all articles
Browse latest Browse all 1507

Trending Articles