A while back someone asked a question about changing the database in a Crystal Report (http://www.experts-exchange.com/Databases/Crystal_Reports/Q_21516382.html
Apparently, even if you've identified a different database in your data source, the report may still point to the old database due to something needing to be set for 'fully qualified table names'. The solution given spoke to a work around in VB 6 using the CRAXDRT reference.
I'm using Crystal Reports 10 in VB .NET. My form class has Import references to CrystalDecisions.Shared and CrystalDecisions.CrystalRe
ne, not CRAXDRT. I use a ReportDocument object to set the Server and Database names depending on who's using the application. I'm running into the same problem: even though I point to a different database, the data is returned from the database originally set.
Here's a sample of my code, most of which is pulled from the example given in the ApplyLogOnInfo help text (Visual Studio .NET):
Dim logOnInfo As New TableLogOnInfo
Dim connectionInfo As New ConnectionInfo
For x = 0 To Me.multiReportDocument.Dat
es.Count - 1
' Get the ConnectionInfo Object.
logOnInfo = New TableLogOnInfo
logOnInfo = multiReportDocument.Databa
connectionInfo = New ConnectionInfo
connectionInfo = multiReportDocument.Databa
' Set the Connection parameters.
If database <> "" Then
e = database
If server <> "" Then
connectionInfo.ServerName = server
If password <> "" Then
connectionInfo.Password = password
If user <> "" Then
connectionInfo.UserID = user
I only specifiy the database and server names. I didn't think I needed to set the user and password parms, even though I allow for them for future use, because of Windows Authentication (won't know the password for the individual user's anyway).
Anyone know what I might be missing? Also, what exactly is the 'Overridden Qualified Table Name' property of the Set Datasource Location window as mentioned in the Q_21516382 document? I'm using Crystal Reports 10 with a SQLOLEDB Provider connection as well and I have yet to see this property.
Thanks in advance,