0
如何在Visual Studio 2008中获得Crystal Reports的ASP.NET控件?我已经下载并安装了很多东西,但SAP网站上的指导对我并不是很有帮助。如何开始使用ASP.NET和Visual Studio 2008中的Crystal Reports?
我需要下载并安装在我的机器上才能创建一个表面显示Crystal Reports的ASP.NET应用程序?
如何在Visual Studio 2008中获得Crystal Reports的ASP.NET控件?我已经下载并安装了很多东西,但SAP网站上的指导对我并不是很有帮助。如何开始使用ASP.NET和Visual Studio 2008中的Crystal Reports?
我需要下载并安装在我的机器上才能创建一个表面显示Crystal Reports的ASP.NET应用程序?
我认为Crystal Report很早以前就与VS进行了整合。即使工具箱中显示了一个报告选项卡,如何使用它,只需将添加项目选项中的Crystal Report文件添加到项目中,然后按照向导。
如何将其绑定到你的网站也simple.Add Crystal报表视图控件工具箱从在你的web form.Then做
protected void Page_Load(object sender, EventArgs e)
{
ReportDocument document = CreateReportDocument("MyReportFile");
CrystalReportViewer1.ReportSource = document;
}
public static ReportDocument CreateReportDocument(string crystalReportName)
{
ReportDocument crdocument = new ReportDocument(); // Report document variable
string reportfile = ConfigurationManager.AppSettings["CrystalReportFilePath"].ToString() + "\\" + crystalReportName + ".rpt";
try
{
DataTable report = new Datatable(); // You should put your data here
crdocument.Load(reportfile);// Load the report being displayed
crdocument.Database.Tables[0].SetDataSource(report);
}
catch (Exception exception)
{
throw exception;
}
return crdocument;
}
我看不出有任何的Crystal Reports选项卡在工具箱中,并且它也不在项目的“添加新项目”对话框中。 – 2010-04-06 19:59:16
还有一个报告选项卡,其中也包含Microsoft报告查看器。对我而言,它在AJAX扩展和HTML之间。 – Steve 2010-04-06 20:24:14
@ Steve.Thank纠正我。我应该在报告标签和@Ryan Shripat中说,只要我知道他们整合,因为我知道VS 2003。 – wonde 2010-04-07 01:35:22