จากบนทความ: ASP.NET Crystal Reports Export PDF เราไปเพิ่มปุ่ม Print แล้วใส่โค้ดดังนี้:
protected void btPrint_Click(object sender, EventArgs e)
{
ReportDocument repDoc = this.Session["ReportSource"] as ReportDocument;
Response.Buffer = false;
Response.ClearContent();
Response.ClearHeaders();
repDoc.PrintToPrinter(1, true, 0, 0);
}
No comments:
Post a Comment