PrintQueueStatus PrintQueueStatus PrintQueueStatus PrintQueueStatus Enum

Определение

Указывает состояние очереди печати или соответствующего принтера.Specifies the status of a print queue or its printer.

Это перечисление имеет атрибут FlagsAttribute, который разрешает побитовое сочетание значений его элементов.

public enum class PrintQueueStatus
[System.Flags]
public enum PrintQueueStatus
type PrintQueueStatus = 
Public Enum PrintQueueStatus
Наследование
PrintQueueStatusPrintQueueStatusPrintQueueStatusPrintQueueStatus
Атрибуты

Поля

Busy Busy Busy Busy 512

Принтер занят.The printer is busy.

DoorOpen DoorOpen DoorOpen DoorOpen 4194304

Открыта дверца принтера.A door on the printer is open.

Error Error Error Error 2

Принтер не может печатать из-за ошибки.The printer cannot print due to an error condition.

Initializing Initializing Initializing Initializing 32768

Идет инициализация принтера.The printer is initializing.

IOActive IOActive IOActive IOActive 256

Идет обмен данными между принтером и сервером печати.The printer is exchanging data with the print server.

ManualFeed ManualFeed ManualFeed ManualFeed 32

Принтер находится в ожидании, пока пользователь не загрузит печатные носители в лоток с ручной подачей.The printer is waiting for a user to place print media in the manual feed bin.

None None None None 0

Состояние не указано.Status is not specified.

NotAvailable NotAvailable NotAvailable NotAvailable 4096

Сведения о состоянии недоступны.Status information is unavailable.

NoToner NoToner NoToner NoToner 262144

В принтере закончился тонер.The printer is out of toner.

Offline Offline Offline Offline 128

Принтер отключен.The printer is offline.

OutOfMemory OutOfMemory OutOfMemory OutOfMemory 2097152

На принтере нет доступной памяти.The printer has no available memory.

OutputBinFull OutputBinFull OutputBinFull OutputBinFull 2048

Выходной лоток принтера полностью заполнен.The printer's output bin is full.

PagePunt PagePunt PagePunt PagePunt 524288

Принтеру не удается напечатать текущую страницу.The printer is unable to print the current page.

PaperJam PaperJam PaperJam PaperJam 8

В принтере замялась бумага.The paper in the printer is jammed.

PaperOut PaperOut PaperOut PaperOut 16

В принтере отсутствует или закончился требуемый для текущего задания печати тип бумаги.The printer does not have, or is out of, the type of paper needed for the current print job.

PaperProblem PaperProblem PaperProblem PaperProblem 64

Бумага в принтере вызывает неопределенную ошибку.The paper in the printer is causing an unspecified error condition.

Paused Paused Paused Paused 1

Очередь печати приостановлена.The print queue is paused.

PendingDeletion PendingDeletion PendingDeletion PendingDeletion 4

Идет удаление задания из очереди печати.The print queue is deleting a print job.

PowerSave PowerSave PowerSave PowerSave 16777216

Принтер находится в режиме экономии энергии.The printer is in power save mode.

Printing Printing Printing Printing 1024

На устройстве идет печать.The device is printing.

Processing Processing Processing Processing 16384

На устройстве выполняется работа, которая необязательно является печатью, если оно сочетает в себе принтер, факсимильный аппарат и сканнер.The device is doing some kind of work, which need not be printing if the device is a combination printer, fax machine, and scanner.

ServerUnknown ServerUnknown ServerUnknown ServerUnknown 8388608

Принтер находится в состоянии ошибки.The printer is in an error state.

TonerLow TonerLow TonerLow TonerLow 131072

В принтере осталось мало тонера.Only a small amount of toner remains in the printer.

UserIntervention UserIntervention UserIntervention UserIntervention 1048576

Для исправления ошибки принтеру требуется вмешательство пользователя.The printer requires user action to correct an error condition.

Waiting Waiting Waiting Waiting 8192

Принтер находится в ожидании задания печати.The printer is waiting for a print job.

WarmingUp WarmingUp WarmingUp WarmingUp 65536

Идет прогрев принтера.The printer is warming up.

Примеры

В следующем примере показано, как использовать это перечисление в рамках опроса всех принтеров на предмет возможных состояний ошибки.The following example shows how to use this enumeration as part of a survey all printers for possible error status.

internal: 
   // Check for possible trouble states of a printer using the flags of the QueueStatus property
   static void SpotTroubleUsingQueueAttributes (System::String^% statusReport, System::Printing::PrintQueue^ pq) 
   {
      if ((pq->QueueStatus & PrintQueueStatus::PaperProblem) == PrintQueueStatus::PaperProblem)
      {
         statusReport = statusReport + "Has a paper problem. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::NoToner) == PrintQueueStatus::NoToner)
      {
         statusReport = statusReport + "Is out of toner. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::DoorOpen) == PrintQueueStatus::DoorOpen)
      {
         statusReport = statusReport + "Has an open door. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::Error) == PrintQueueStatus::Error)
      {
         statusReport = statusReport + "Is in an error state. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::NotAvailable) == PrintQueueStatus::NotAvailable)
      {
         statusReport = statusReport + "Is not available. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::Offline) == PrintQueueStatus::Offline)
      {
         statusReport = statusReport + "Is off line. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::OutOfMemory) == PrintQueueStatus::OutOfMemory)
      {
         statusReport = statusReport + "Is out of memory. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::PaperOut) == PrintQueueStatus::PaperOut)
      {
         statusReport = statusReport + "Is out of paper. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::OutputBinFull) == PrintQueueStatus::OutputBinFull)
      {
         statusReport = statusReport + "Has a full output bin. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::PaperJam) == PrintQueueStatus::PaperJam)
      {
         statusReport = statusReport + "Has a paper jam. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::Paused) == PrintQueueStatus::Paused)
      {
         statusReport = statusReport + "Is paused. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::TonerLow) == PrintQueueStatus::TonerLow)
      {
         statusReport = statusReport + "Is low on toner. ";
      }
      if ((pq->QueueStatus & PrintQueueStatus::UserIntervention) == PrintQueueStatus::UserIntervention)
      {
         statusReport = statusReport + "Needs user intervention. ";
      }

      // Check if queue is even available at this time of day
      // The method below is defined in the complete example.
      ReportAvailabilityAtThisTime(statusReport, pq);
   };
// Check for possible trouble states of a printer using the flags of the QueueStatus property
internal static void SpotTroubleUsingQueueAttributes(ref String statusReport, PrintQueue pq)
{
    if ((pq.QueueStatus & PrintQueueStatus.PaperProblem) == PrintQueueStatus.PaperProblem)
    {
        statusReport = statusReport + "Has a paper problem. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.NoToner) == PrintQueueStatus.NoToner)
    {
        statusReport = statusReport + "Is out of toner. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.DoorOpen) == PrintQueueStatus.DoorOpen)
    {
        statusReport = statusReport + "Has an open door. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.Error) == PrintQueueStatus.Error)
    {
        statusReport = statusReport + "Is in an error state. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.NotAvailable) == PrintQueueStatus.NotAvailable)
    {
        statusReport = statusReport + "Is not available. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.Offline) == PrintQueueStatus.Offline)
    {
        statusReport = statusReport + "Is off line. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.OutOfMemory) == PrintQueueStatus.OutOfMemory)
    {
        statusReport = statusReport + "Is out of memory. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.PaperOut) == PrintQueueStatus.PaperOut)
    {
        statusReport = statusReport + "Is out of paper. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.OutputBinFull) == PrintQueueStatus.OutputBinFull)
    {
        statusReport = statusReport + "Has a full output bin. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.PaperJam) == PrintQueueStatus.PaperJam)
    {
        statusReport = statusReport + "Has a paper jam. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.Paused) == PrintQueueStatus.Paused)
    {
        statusReport = statusReport + "Is paused. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.TonerLow) == PrintQueueStatus.TonerLow)
    {
        statusReport = statusReport + "Is low on toner. ";
    }
    if ((pq.QueueStatus & PrintQueueStatus.UserIntervention) == PrintQueueStatus.UserIntervention)
    {
        statusReport = statusReport + "Needs user intervention. ";
    }

    // Check if queue is even available at this time of day
    // The method below is defined in the complete example.
    ReportAvailabilityAtThisTime(ref statusReport, pq);
}
' Check for possible trouble states of a printer using the flags of the QueueStatus property
Friend Shared Sub SpotTroubleUsingQueueAttributes(ByRef statusReport As String, ByVal pq As PrintQueue)
    If (pq.QueueStatus And PrintQueueStatus.PaperProblem) = PrintQueueStatus.PaperProblem Then
        statusReport = statusReport & "Has a paper problem. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.NoToner) = PrintQueueStatus.NoToner Then
        statusReport = statusReport & "Is out of toner. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.DoorOpen) = PrintQueueStatus.DoorOpen Then
        statusReport = statusReport & "Has an open door. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.Error) = PrintQueueStatus.Error Then
        statusReport = statusReport & "Is in an error state. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.NotAvailable) = PrintQueueStatus.NotAvailable Then
        statusReport = statusReport & "Is not available. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.Offline) = PrintQueueStatus.Offline Then
        statusReport = statusReport & "Is off line. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.OutOfMemory) = PrintQueueStatus.OutOfMemory Then
        statusReport = statusReport & "Is out of memory. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.PaperOut) = PrintQueueStatus.PaperOut Then
        statusReport = statusReport & "Is out of paper. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.OutputBinFull) = PrintQueueStatus.OutputBinFull Then
        statusReport = statusReport & "Has a full output bin. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.PaperJam) = PrintQueueStatus.PaperJam Then
        statusReport = statusReport & "Has a paper jam. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.Paused) = PrintQueueStatus.Paused Then
        statusReport = statusReport & "Is paused. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.TonerLow) = PrintQueueStatus.TonerLow Then
        statusReport = statusReport & "Is low on toner. "
    End If
    If (pq.QueueStatus And PrintQueueStatus.UserIntervention) = PrintQueueStatus.UserIntervention Then
        statusReport = statusReport & "Needs user intervention. "
    End If

    ' Check if queue is even available at this time of day
    ' The method below is defined in the complete example.
    ReportAvailabilityAtThisTime(statusReport, pq)
End Sub

Комментарии

Как и PrintQueue класс, это перечисление обрабатывает очередь печати и физический принтер (или устройство) как одну единицу.Like the PrintQueue class, this enumeration handles the print queue and the physical printer (or device) as one unit. Некоторые значения представляют состояние физического устройства, а другие — состояние программы очереди печати, которая работает на сервере печати.Some values represent the status of the physical device and others represent the status of the print queue program that is running on the print server.

Это перечисление используется для предоставления значений QueueStatus свойству PrintQueue класса.Use this enumeration to provide values for the QueueStatus property of the PrintQueue class.

Применяется к

Дополнительно