Operation Failed error using FAXCOMEXLib



I am currently in the process of building a vb.net windows application that
will be used to send faxes and monitor these faxes as they are sent. In the
project I am building the fax functionality into a single web form in order
to encapsulate this functionality. The error I am receiving has brought me to
the point of starting a brand new project with just the web-form for faxing.
I am using code provided by Microsoft:

This is throwing an error when it reaches the following line of code:
JobID = objFaxDocument.ConnectedSubmit(objFaxServer)

The error it is throwing is as follows:
exc.Message: 'Operation Failed'
exc.Source: 'FaxComEx.FaxDocument.1'

The entire code snippet that I am using in the form load is below:

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load

'Declare fax variables...
Dim objFaxServer As New FAXCOMEXLib.FaxServer()
Dim objFaxDocument As New FAXCOMEXLib.FaxDocument()
Dim JobID As Object


'Connect to the fax server...

'Set the fax body
objFaxDocument.Body = "c:\fax.txt"

'Name the document
objFaxDocument.DocumentName = "My First Fax"

'Set the fax priority
objFaxDocument.Priority = FAX_PRIORITY_TYPE_ENUM.fptHIGH

'Add the recipient with the fax number 12225550100
objFaxDocument.Recipients.Add("555-5555", "Bud")

'Choose to attach the fax to the fax receipt
objFaxDocument.AttachFaxToReceipt = True

'Provide the cover page note
objFaxDocument.Note = "Here is the info you requested"

objFaxDocument.Subject = "Today's fax"

'Set the sender properties.
objFaxDocument.Sender.Title = "Mr."
objFaxDocument.Sender.Name = "Bob"
objFaxDocument.Sender.City = "Cleveland Heights"
objFaxDocument.Sender.State = "Ohio"
objFaxDocument.Sender.Company = "Microsoft"
objFaxDocument.Sender.Country = "USA"
objFaxDocument.Sender.Email = "(e-mail address removed)"
objFaxDocument.Sender.FaxNumber = "12165555554"
objFaxDocument.Sender.HomePhone = "12165555555"
objFaxDocument.Sender.OfficeLocation = "Downtown"
objFaxDocument.Sender.OfficePhone = "12165555553"
objFaxDocument.Sender.StreetAddress = "123 Main Street"
objFaxDocument.Sender.TSID = "Office fax machine"
objFaxDocument.Sender.ZipCode = "44118"
objFaxDocument.Sender.BillingCode = "23A54"
objFaxDocument.Sender.Department = "Accts Payable"

'Save sender information as default

'Submit the document to the connected fax server
'and get back the job ID.
JobID = objFaxDocument.ConnectedSubmit(objFaxServer)

MsgBox("The Job ID is :" & JobID(0))

Catch exc As Exception

MsgBox("Exception message: " & exc.Message & vbCrLf & "Exception
Source: " & exc.Source)

End Try

End Sub

Renu Bhattar \(MSFT\)

Instead of objFaxDocument.Body = "c:\fax.txt"
, try objFaxDocument.Body = "c:\\fax.txt"


Renu Bhattar [MSFT]

Microsoft Printing, Imaging and Faxing
This posting isprovided "AS IS" with no warranties and confers no rights.
Please do not send mail directly to this aloas. This alias is for newsgroup
purposes only.


This problem has been resolved. After pounding my head against a wall for
about a day, it turns out that I needed to uninstall the MS Fax service and
then re-install it onto Windows Server 2003 Standard Edition.

I tested this by just trying to send out a fax through the fax console
manually. This failed and signified to me that somehow the MS Fax Service
installation became corrupted. Nothing changed on the fax server so this is
slightly worrying, but then again what fun would it be if it worked all the
Dec 31, 2007
Reaction score
Had the same problem! A fax server installed on a Windows 2003 machine (2003test) and a Windows service (C# app), running on a different machine and trying to connect to this fax server and send a fax. I was receiving “Operation failed”. It came into my mind (kind of late, though!!!!) to retrieved the “base exception” which said something about an error: Interop.FaxComExLib … and it had this number: 0x….710D8. Reading a posting of a fellow from Microsoft, he said that 10D8 is actually the error code. When you turn that into decimal you get 4312 and if you do “net helpmsg 4312” into a DOS command you get the following error: “The object identifier does not represent a valid object” – which is the REAL ERROR msg. Came into my mind then to access my printer from the machine where my app was running so I went: Start-Run and then typed: \\2003test\fax and I was prompted to install the “shared 2003 fax” on this machine (the same way you install a network printer on your desktop) and this seemed to solve the issue! Also, my Windows service had to run under a certain user account and this user account had to exist (and have Admin rights) on my 2003test machine, if not, you get another misleading error: The API version does not support the current operation ….or something like that. Hope this helps!
Nov 25, 2015
Reaction score
I have read numerous post to resolve "Operations Failed" error Interop.FaxComExLib . The Above Solution is the only thing that worked. Go to Start -> Run, Type "\\YourFaxServer\Fax", reinstall Fax client using wizard even though you have Fax Client installed and nothing changed in windows server 2003.

Thank you so much astely!!!

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