PowerShell Logo Small

Remove-Printer



This is the built-in help made by Microsoft for the command 'Remove-Printer', in PowerShell version 3 - as retrieved from Windows version 'Microsoft Windows Server 2012 Standard' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.

SYNOPSIS

Removes a printer from the specified computer.

SYNTAX


Remove-Printer [-Name] <String> [-AsJob [<SwitchParameter>]] [-CimSession <CimSession>] [-ComputerName <String>] [-PassThru
[<SwitchParameter>]] [-ThrottleLimit <Int32>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]] [<CommonParameters>]
Remove-Printer [-AsJob [<SwitchParameter>]] [-CimSession <CimSession>] [-PassThru [<SwitchParameter>]] [-ThrottleLimit <Int32>] -InputObject
<CimInstance> [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]] [<CommonParameters>]



Search powershellhelp.space

DESCRIPTION


The Remove-Printer cmdlet deletes a printer from the specified computer. You can specify the printer to remove by using either a printer
object retrieved by Get-Printer, or by specifying a printer name.


You can use wildcard characters with Remove-Printer. You can use Remove-Printer in a Windows PowerShell remoting session.


You do not need administrator privileges to use Remove-Printer.



<

RELATED LINKS

Add-Printer
Rename-Printer
Get-Printer
Set-Printer

REMARKS

<

Examples


Example 1: Remove a specific printer

PS C:\> Remove-Printer –Name "Microsoft XPS Document Writer"



This command removes the printer named "Microsoft XPS Document Writer" from the local computer.




Example 2: Remove a specific printer using a printer object

PS C:\> $printer = Get-Printer –Name "Microsoft XPS Document Writer"



PS C:\> Remove-Printer –InputObject $printer



This set of commands retrieves a printer object into a variable ($Printer) using Get-Printer, and then removes the specified printer using
Remove-Printer.