Files
claudetools/clients/cascades-tucson/scripts/add-nurse-printer.ps1
Howard Enos 8d2ca14cac sync: auto-sync from HOWARD-HOME at 2026-07-17 14:14:41
Author: Howard Enos
Machine: HOWARD-HOME
Timestamp: 2026-07-17 14:14:41
2026-07-17 14:15:20 -07:00

22 lines
1.0 KiB
PowerShell

# Add the nurse printer as a machine-level connection via Point and Print
# This makes it available to ALL users who log in
$printer = '\\CS-SERVER\Nurses - Brother MFC-L8900CDW'
# Check if already installed as local/machine printer
$existing = Get-Printer -Name $printer -ErrorAction SilentlyContinue
if ($existing -and $existing.Type -eq 'Local') {
Write-Output "Already installed as machine printer: $printer"
} else {
# Use rundll32 to install as machine-level
& rundll32 printui.dll,PrintUIEntry /ga /n $printer 2>&1
Write-Output "Added machine-level printer connection: $printer"
}
# Set as default for the machine
# Also add the Health Services printer the same way
$printer2 = '\\CS-SERVER\Health Services - Konica Minolta C368'
& rundll32 printui.dll,PrintUIEntry /ga /n $printer2 2>&1
Write-Output "Added machine-level printer connection: $printer2"
Write-Output ""
Write-Output "Both printers will be available to all users on next login."
Write-Output "Current printers:"
Get-Printer | Select-Object Name, Type | Format-Table -AutoSize