The user's default printer goes back well in the user's remote desktop session but is not set as the default printer in MDE.

Here is a small PowerShell script to run at session startup to fix the printer

# Clear any existing errors.
#
"Waiting for printers to be created"

# the following line may need to be uncommitted to wait for session printers to be auto-created.
#Start-sleep 10

$error. clear
() $registrykey = "registry:: HKEY_CURRENT_USERSOFTWAREMicrosoftWindows NTCurrentVersionWindo

ws" # set the locat
io
n # set-location-path $registrykey-ErrorAction SilentlyContinu

e # retrieve the default printer Properties.

# $wmiDefaultPrinter = Get-WmiObject-query "SELECT * FROM WIN32_PRINTER WHERE default = TRUE"

# If the default printer exists then set the registry values.

# If ($wmiDefaultPrinter-$null) {"
se
tting the Windows default printer registry key" se
t-ItemProperty-path $registrykey-name "device"-value ($wmiDefaultPrinter. name + ", winspool, Ne00:"
) write-host "your default printer is" $ wmiDefaultPrinter.N
ame} else
{set-ItemProperty-path $registrykey-name "device"-value "Microsoft print to PDF, winspool, Ne01:
"}

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.