How to retrieve the status of a fax outgoing job

Joined
Nov 15, 2007
Messages
1
Reaction score
0
Hi all,

I am trying to retrieve the job status of fax jobs in the fax outgoing queue and am facing problems with the status code I get back. I am having trouble mapping the status code with the status name like Pending or Paused or Canceled, etc. Here is the code snippet.
______________________________________________________________________________
FaxOutgoingJobs fOutJobs = fs.Folders.OutgoingQueue.GetJobs();

try
{

IEnumerator iEnum = fOutJobs.GetEnumerator();
iEnum.Reset();

while ((!(flagValue)) & (iEnum.MoveNext()))
{
fOutJob = (FaxOutgoingJob)iEnum.Current;
count++;

if (jobID.Equals(fOutJob.Id))
flagValue = true;

}

}
catch (InvalidOperationException ioe)
{
Console.WriteLine("From pollFaxStatus() : InvalidOperationException has been caught");
Console.WriteLine("Stack Trace : " + ioe.StackTrace);
}

if (flagValue)
{
Console.WriteLine("Value of faxStatusResponse after setting it is : " + faxStatusResponse);
Console.WriteLine("Job Status is : " + fOutJob.Status.ToString());
Console.WriteLine("Job Status in General format : " + fOutJob.Status.ToString("G"));
Console.WriteLine("Job Status in Decimal format : " + fOutJob.Status.ToString("D"));
}
______________________________________________________________________________

The above "jobID" variable is the input job ID that I pass to my method. I know that this job is PAUSED.

All of the above Console.WriteLine statements result in "49" as the status. fOutJob.Status returns FAX_JOB_STATUS_ENUM object. In the FAX_JOB_STATUS_ENUM enum type, fjsPAUSED is one of the constants which has the value "0x00000010" assigned to it.

Question : How can I get to print "fjsPAUSED" from the status code 49 ? How is 49 related to 0x00000010 ? When I convert 49 to its hex equivalent, I get 00000031.

Can someone please tell me what this 49 means ?

Thanks
Chapsi
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top