About PrintPreview Problem?-Plz respond about my query [modified]
-
Hi all, I want to see print previw of my resulted form......but am trying with many ways it is just displaying empty form only.it is not going to disaply the content of my windows form....can u plz give for that solution. this is my code....
private void printPreviewToolStripMenuItem_Click(object sender, EventArgs e)
{
printPreviewDialog1.Document = this.printDocument1 ; // Attach PrintDocument to PrintPreview Dialog
printPreviewDialog1.FormBorderStyle = FormBorderStyle.Fixed3D ;
printPreviewDialog1.SetBounds(20, 20, this.Width, this.Height);if (printPreviewDialog1.ShowDialog()== DialogResult.OK)
{
this.printDocument1.Print();}
what is the wrong of code and why it is diplaying empty form when i click the printpreview option. Can u plz give me quick reply
modified on Friday, December 5, 2008 6:46 AM