I already have a Word document with a legal size.
When I try to send it directly to the printer, the document is always considered like a letter size; the part at the end of each page which the size is greater than a letter size is truncated.
What can I do to send the document with the correct size?
Here is my code:
- Code: Select all
Document myDoc = new Document();
myDoc.LoadFromFile("myFile.doc");
PrintDialog dialog = new PrintDialog
{
AllowPrintToFile = true,
AllowCurrentPage = true,
AllowSomePages = true,
UseEXDialog = true
};
myDoc.PrintDialog = dialog;
if (dialog .ShowDialog() == DialogResult.Ok)
myDoc.PrintDocument.Print();