如何在Visual Studio 2010上将XtraReport连接到Windows窗体(这也必须使用XtraGrid进行报表查看)
答案 0 :(得分:1)
并尝试在表单中使用此代码
public partial class YourForm : XtraForm
{
private YourXtraReport report;
public YourForm(PrintDocument document )
{
InitializeComponent();
report = new PrintingDocumentReport(document);
}
private void PrintingFormLoad(object sender, EventArgs e)
{
printControl1.PrintingSystem = report.PrintingSystem;
report.CreateDocument();
}
}