打印对话框中如何显示总页数
本帖最后由 yyixin 于 2010-04-11 15:10:42 编辑
的打开打印预览的窗口时跳出上面的提示框
这里的总页数如何设置。谢谢
[解决办法]
private void menuItemPrintV_Click(object sender, System.EventArgs e)
{
pd = new PrintDocument();
PrintPreviewDialog ppd = new PrintPreviewDialog();
ppd.WindowState = FormWindowState.Maximized;//设定窗体最大化
ppd.PrintPreviewControl.Zoom = 1;
ppd.FormBorderStyle = FormBorderStyle.Fixed3D;
//pd.PrinterSettings.MaximumPage = 10;
pd.PrintPage += new PrintPageEventHandler(this.pd_PrintPage);
ppd.Document = pd;
ppd.ShowDialog();
}
private void pd_PrintPage(object sender, PrintPageEventArgs e)
{
…………
}