Problem connecting Crystal Reports after password change

It seems a lot of people have been having similar issues to this so I'll try to be as precise as possible when explaining my problem.


I am working on a web application, a simple "Log In, and select your report"..So I am working on Visual Studio 2005 Beta 2 and had absolutely no problem creating the reports or displaying them, that is, until the password I use to log into the database(via ODBC) expired. Once I reset this password none of the reports connect directly, they all display a login screen no matter what I do. It seems this password I had when creating the Reports somehow got hardcoded somewhere in the report itself because no matter what I do or change I still get that dreaded login screen when I select a report for display.

I tried recreating the ODBC connection, but still had the same problem. I tried making a connection to the database via code, I checked on the web and at the MSDN and did this:

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load


      
        Dim myTableLogonInfos As New CrystalDecisions.Shared.TableLogOnInfos()
        Dim myTableLogoninfo As New CrystalDecisions.Shared.TableLogOnInfo()
        Dim myConnectionInfo As New CrystalDecisions.Shared.ConnectionInfo

        With myConnectionInfo
            .ServerName = "xxxx"
            .DatabaseName = "xxxx"
            .UserID = "xxxx"
            .Password = "xxxx"
        End With
        myTableLogoninfo.ConnectionInfo = myConnectionInfo
        myTableLogoninfo.TableName = "UNC-Request for Service"
        CrystalReportViewer1.LogOnInfo = myTableLogonInfos
        CrystalReportViewer1.ReportSource = "Closedcalls.rpt"




    End Sub



Can anyone shed some light on this I really do not want to recreate these reports from scratch every time the password expires!

Ohh and by the way, I have no power over how frequent this password expires so making it static wont be possible.


Answer this question

Problem connecting Crystal Reports after password change

  • ParkSys

    Hello,

    Here is an article that walks through passing Logon information at runtime with Visual Studio .NET:

    http://support.businessobjects.com/library/kbase/articles/c2010275.asp

    I'm not sure if your issue had something to do with the Beta 2 build, but I would be interested to know if you are still having the same issue with the RTM version.

    Keith - Business Objects



  • mediterian

    VS 2005 got rid of this capability, you will need to create a ReportDocument and use the Load method
  • CKa

    Thanks for the info, I am trying to implement this, but i am getting an error in this part..

     

    Dim RepDoc As New OpenedCalls()(openedcalls is not defined)

     

    OpenedCalls is the name of the Report. It seems the page is not recognizing that Report as a class.


  • Flashx

    Thanks for the info guys.
  • Problem connecting Crystal Reports after password change