|
Use the following code to get all printers. Thus the dropdownlist contains list of installed printers. If am saving Microsoft XPS Document Writer as my printer and try to print using the printer a window is opened for saving the print document.But when I host the application and try to print with Microsoft XPS Document Writer the page shows a javascript error or the page become struct.I think it is because if am selecting Microsoft XPS Document Writer as printer its not a valid printer and shows the dialog window to save the document but after hosting save window is opened and the timeout occurs therefore the errors occurs.If am selecting a valid printer it works fine. Can you help me to avoid Microsoft XPS Document Writer from my installed printers lisrt or help any way
//Get all the Installed printers foreach (String strPrinterName in PrinterSettings.InstalledPrinters) { ddlSetPrinter.Items.Add(strPrinterName); }
|