var report = new ReportDocument(); report.Load(Cr6Path); report.SetDatabaseLogon(repUser, repPass, repServer, repData, false); report.SetParameterValue("Stu_Id", Cr6StuId); report.SetParameterValue("Name", Cr6StuName); report.SetParameterValue("Level", Cr6StudentLevel); CrystalReportsViewer1.ViewerCore.ReportSource = report;
var report = new ReportDocument(); report.Load(Cr6Path); report.SetDatabaseLogon("sa", "*******", "VM-01", "DB_School", false); report.SetParameterValue("Stu_Id", Cr6StuId); report.SetParameterValue("Name", Cr6StuName); report.SetParameterValue("Level", Cr6StudentLevel); CrystalReportsViewer1.ViewerCore.ReportSource = report;
Quote:Logon information is applied only to tables with the same server name and database name. This method cannot be used to change the name of the database, or the server, that was originally specified in the report.
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)