2010-11-26 37 views
0

我正在使用Crystal Report 2010與C#,有一個WinForm,並希望顯示M的頁面N給用戶在Label中同時打印水晶報表。 我該如何推敲?如何找到水晶報表打印計數?

在我的ReportViewer實現的代碼:使用系統

; using CrystalDecisions.CrystalReports.Engine; using CrystalDecisions.Windows.Forms; using CrystalDecisions.Web;

命名空間ComboSearch.Reports { 公共部分類的ReportViewer:System.Web.UI.Page {

 ReportDocument rpt = new ReportDocument(); 

    protected void Page_Load(object sender, EventArgs e) 
    { 
     if (!IsPostBack) 
     { 
      string path = Server.MapPath("Employee.rpt"); 
      rpt.Load(path); 
      CrystalReportViewer1.ReportSource = rpt;     
     } 
    } 
} 

} 在此先感謝。

+0

爲您重新授權。你現在應該得到更快的答案。 – PowerUser 2010-12-02 13:59:33

回答

0

顯示「M頁面N」,打印報告可以通過將報告作爲字段插入到報告本身,然後根據您的要求進行定位。

要插入它,請使用特殊字段選項插入「頁面N of M」字段。