第1个回答 推荐于2018-03-29
Font printFont ;
privatevoid pd_PrintPage(object sender, PrintPageEventArgs ev)
{
ev.Graphics.DrawString (richTextBox1.Text);
ev.HasMorePages = true;
}
publicvoid Printing()
{
printFont = new Font("Arial", 10);
PrintDocument pd = new PrintDocument();
pd.PrintPage += new PrintPageEventHandler(pd_PrintPage);
// 打印文档
pd.Print();
}
设置一个打印按钮,调用Printing();如果没有打印机,网上下载一个虚拟打印机试验本回答被网友采纳