title: Print range not working even if values are set
body: <p>I have a simple printing solution set up and normal printing works fine(tested it a couple of times), however when I use the PrintDialog to specify a custom page range, it is as if the range is ingored. When I debug I inspect the printDocument object and confirm that the range values are correct but the end product that the printer produces does not much the values I gave it.</p>
  
  <p>Here is my code :</p>
  
  <pre><code>            printDialog.Document = printdoc;
              printDialog.AllowSomePages = true;
  
              if (printDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
              {
                  printdoc.PrinterSettings.FromPage = printDialog.PrinterSettings.FromPage;
                  printdoc.PrinterSettings.ToPage = printDialog.PrinterSettings.ToPage;
                  printdoc.PrinterSettings.PrintRange = printDialog.PrinterSettings.PrintRange;
  
                  printPreviewDialog.Document = printdoc;
                  printPreviewDialog.FindForm().WindowState = FormWindowState.Maximized;
                  printPreviewDialog.ShowDialog();
              }
  </code></pre>
  
  <p>*Note - printdoc is a instance of System.Drawing.Printing.PrintDocument. I added code in the PrintDocument's PrintPage event handler to populate the page I'm printing.</p>