private void btnsave_Click(object sender, EventArgs e)
{
ReportDocument cryRpt = new ReportDocument();
cryRpt.Load("CrystalReport1.rpt ");
crystalReportViewer1.ReportSource = cryRpt; crystalReportViewer1.Refresh();
crystalReportViewer1.ReportSource = cryRpt;
crystalReportViewer1.Refresh();
}
}
Priya NaikPosted Jul 4, 2016, 1:25 AM
report.Load(Server.MapPath("CrystalReport1.rpt"));
report.SetDatabaseLogon("dbloginname", "dbpassword", @"servername", "dbname");
report.SetDataSource(ds);
CrystalReportViewer1.ReportSource = report;
Session["ReportSource"] = report;
ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "window.open('Report.aspx?parameter=Report', '_blank', 'width=2000px,height=900px');", true);