public virtual void Print() { PrintDocument printDocument = new PrintDocument(); PrintDialog printDialog = new PrintDialog(); printDialog.Document = printDocument; if (printDialog.ShowDialog() == DialogResult.OK) { printDocument.PrintPage += printDocument_PrintPage; printDocument.Print(); } }