Does PrintQueue or PrintTicket has any property or method to determine the selected printer is a virtual printer? For example, the process should restrict M/S Xps Document Writer, Fax, Send To OneNote, PDF Printer etc. Only actual printers should be filtered out from LocalPrintServer and provide a list dynamically.
using (var _LocalPrintServer = new LocalPrintServer())
{
foreach (PrintQueue _pq in _LocalPrintServer.GetPrintQueues())
{
// To Find some way to determine this _pq is NOT a virtual printer
}
}
You will need to probe the properties in
Win32_PrinterclassMaybe you could check the
languagesfield for postscipt or pcl (only a guess), though you might just have to check the difference between all your printers to find an loosely indicative way.In any case i can be fairly confident there is no way to exactly check for what you want as there is no field called virtual printer as to your specs.