I have discovered a solution to the issue.
import wmi
c = wmi.WMI()
wql = "SELECT * FROM WIN32_PRINTER WHERE Default = TRUE"
for printer in c.query(wql):
selectedPrinter = printer.caption
where selectPrinter is the device name of the printer.
Hope this helps somebody in the future.
J
I was able to discover that a powershell command does in fact find the
correct default printer.
powershell.exe -command "& {(Get-WmiObject -class win32_printer | where
{$_.default -eq $true}).name}"
or
Get-WmiObject -query "SELECT * FROM WIN32_PRINTER WHERE Default = TRUE"
is there somethi
Hi John,
In the Windows RDP client, under "Show Options" -> "Local Resources" ->
section "Local devices and resources" is "Printers" checked?
I haven't tried what you're referring to, but perhaps that setting is
relevant to your problem?
- Terry
On Tue, Feb 25, 2020 at 5:51 PM john wrote:
> H
Thanks for the response - and yes I do have the printers checkbox -
checked. It returns a blank.
Johnf
On 2/26/20 8:48 AM, Terry Davis wrote:
Hi John,
In the Windows RDP client, under "Show Options" -> "Local Resources"
-> section "Local devices and resources" is "Printers" checked?
I hav