Cmdlet
Stop-OfficePrintJob
Cancels a print job submitted with Send-OfficePrinter and returns its state afterwards. Requires PowerShell 7.4 or newer.
Syntax
Stop-OfficePrintJob
[-JobId] <String>
[-PrinterName] <String>
[<CommonParameters>]#Parameter set:
DefaultDescription
A job that has already finished is reported unchanged. Pages the printer has already received may still print.
Examples
Cancel a submitted job.
Send-OfficePrinter -Path .\Report.pdf -PrinterName 'Office printer' | Stop-OfficePrintJobParameters
- -JobId String
- The job identifier from the receipt.
- -PrinterName String
- The printer queue name or IPP URI from the receipt.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.