I'm using Cryatal Reports 2008 Developer to create reports based on SQL database.
In my program, Visual Studio 2010, I change database at runtime with follow:
Dim tableLogOnInfo As New TableLogOnInfo
For Each dbTable As Table In rpt.Database.Tables
tableLogOnInfo = dbTable.LogOnInfo
tableLogOnInfo.ConnectionInfo.AllowCustomConnection = True
tableLogOnInfo.ConnectionInfo.ServerName = gclsConfig.odbcDNSReports
tableLogOnInfo.ConnectionInfo.DatabaseName = gclsConfig.DatabaseReports
tableLogOnInfo.ConnectionInfo.UserID = gclsConfig.SQLUser
tableLogOnInfo.ConnectionInfo.Password = gclsConfig.SQLPassword
tableLogOnInfo.ConnectionInfo.LogonProperties.Add(New NameValuePair2("UseDSNProperties", 0))
dbTable.ApplyLogOnInfo(tableLogOnInfo)
dbTable.Location = gclsConfig.DatabaseReports + ".dbo." + dbTable.Location.Substring(dbTable.Location.LastIndexOf(".") + 1))
Next dbTable
where rpt is As ReportDocument.
All worked fine with SP4. After installed SP5 the instruction dbTable.Location fail with messate: table not exist in document.
In design time thare are no problem ...
Anyone can help me ?
Thanks
Filippo