Platform SDK: Fax Services

IFaxJob::SetStatus

The IFaxJob::SetStatus method changes the job status of a specified FaxJob object. Call the IFaxJob::SetStatus method to pause, resume, cancel, or restart a specified fax job.

Visual Basic Reference

HRESULT SetStatus(
  LONG Command  // job command value
);

Parameters

Command
[in] Specifies a LONG variable that indicates the job command to perform. This parameter can be one of the following values.
Value Meaning
JC_DELETE Cancel the specified fax job. The job can be active or queued.
JC_PAUSE Pause the specified queued fax job. If the fax job is active, the fax service pauses the job when it returns to the queued state.
JC_RESUME Resume the paused fax job.
JC_RESTART Restart the specified fax job.

Return Values

Returns an HRESULT value indicating success or failure. If the method succeeds, it returns S_OK. Otherwise, it returns a COM-defined error code.

You should not check directly for success or failure. Use the COM SUCCEEDED and FAILED macros instead.

Remarks

You can call the IFaxJob::get_QueueStatus method to retrieve the job queue status of a fax job.

For more information, see Managing Fax Jobs.

Requirements

  Windows NT/2000: Requires Windows 2000.
  Windows 95/98: Unsupported.
  Header: Declared in faxcom.h.
  Import Library: Included as a resource in faxcom.dll.

See Also

Fax Service Client Application Programming Interface Overview, Fax Service Client API Interfaces, IFaxJob, IFaxJobs, IFaxJob::get_QueueStatus