unable to send fax

P

Pavan Kumar

Hi All,
I had developed a application which sends fax using faxcom.dll in windows
2000 .Currently i had ported that application in 2003 server.I am unable to
send faxes .
The problem is that it is says operation timed out when i had called
objDoc.send() method in the below code.

//Getting all the messages from the Loop

foreach(PopMessage objMsg in objPop.Messages)

{

log.Debug("entered into the loop");

strMessage = objMsg.Message.Text.Trim();

Filename="\\Fax"+objMsg.Uid+".txt";

Filepath=ConfigurationSettings.AppSettings["Filepath"];

objSw = new StreamWriter(Filepath+Filename,false);

objSw.Write(strMessage);

objSw.Close();

strFaxnumber= getFaxNumber(objMsg.Message.Subject.ToString());

if(isnumeric(strFaxnumber))

{

FaxDoc objDoc = (FaxDoc)objFsc.CreateDocument(Filepath+Filename);

objDoc.FaxNumber = strFaxnumber;

objDoc.FileName=Filepath+Filename;

objDoc.SenderName=FaxSenderName;

log.Debug("Fax Number = " + strFaxnumber + " File Name = " +
Filepath+Filename + " Sender Name ="+ FaxSenderName);

objDoc.ConnectionObject=objFsc;

ShellExecute((int)objProcessHandler.Handle,"printto",Filepath+Filename
,"Fax",null,0);

objDoc.Send();

log.Debug("Fax sent");

}

else

{

log.Debug("Subject of the Email doesnot contain fax number "+
objMsg.Message.Subject.ToString());

}

any help is appreciated.

Regards

Pavan
 
R

Raghavendra R [MSFT]

I think this can be due to either of following reasons
1. You fax service is not started. You get time out error when fax is not
ready to accept connections
2. You are trying to connect to a remote shared fax service and faxcom.dll
is restricted to only local machine connections.

Also tell us what's the error code you are seeing exactly. One note about
your program - you can set any type of file to FaxDoc.FileName and it will
do the conversion to TIFF for you, provided there is a registered
application for that extension. So you need not call ShellExecute in a way.

HTH.

--
Raghavendra R
Microsoft Printing, Imaging and Fax Team
This posting is provided "AS IS" with no warranties, and confers no rights.
Please do not send email directly to this alias. This alias is for newsgroup
purposes only.
 

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

Similar Threads

Cover pages 3

Top