printing files but when we gives following code for printing file.
print document does not get the file from the system.
if (printersList.Items.Count > 0)
{
pr = new PrintDocument();
pr.PrinterSettings = new PrinterSettings();
pr.PrinterSettings.PrinterName = printersList.SelectedItem.
pr.PrinterSettings.Copies = Convert.ToInt16(txtNoOfCopies.
//if (File.Exists(filename ))
//{
pr.PrinterSettings.
// pr.PrinterSettings.
pr.Print();
//}
// }
printer gets the command but print blank pages.
in highlited line printersetting does not get the file name.
plz suggest the right solution if possible.
Replies
Know the answer? Post it — somebody with the same question will find it here.