Link to home
Start Free TrialLog in
Avatar of cossy74
cossy74

asked on

Sending a Fax using VB on XP

Hi,

i have this code

Public Sub SendFax()
  Dim FaxServer As Object
  Dim FaxDoc As Object
 
  Set FaxServer = CreateObject("Faxserver.FaxServer")
 
  'Create FaxServer object...
  '<---This line does not produces an error.
  If (FaxServer.Connect("Fax")) Then
    MsgBox "Failed to connect"
  End If
 
  'Create document
  Dim FaxFile As String
  FaxFile = "C:\Work\Projects\Serck Controls\Vb\FaxSender\Message.txt"
  Set FaxDoc = FaxServer.CreateDocument(FaxFile)
 
  FaxDoc.FaxNumber = "0,49543543"
  FaxDoc.RecipientName = "John Doe"
  Dim iReturn As Integer
  iReturn = FaxDoc.Send                     '<--- Failed to Send
  FaxDoc = Nothing
  FaxServer.Disconnect
  FaxServer = Nothing
 
End Sub

I have referenced the fxscom.dll but it fails to send can anyone help?
Do i have to set anything up in the xp enviroment?
ASKER CERTIFIED SOLUTION
Avatar of cristy56
cristy56

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of cristy56
cristy56

Hi, how is your problem going on ? have u solved it ?

Cristy

Avatar of cossy74

ASKER

Sorry, i went away on holidays an got back this morning.
Crisy56: No the problem exists because to solutions require exchange which i donot have.
If i have read these answer wrongly please advise.