wertigol

wertigol

  • NA
  • 1
  • 0

Access denied for FaxServer in ASP.NET

Mar 4 2005 12:03 PM
Hi all and many thanks for your help. I try to develop an ASP.NET application able to send faxes, but I found a great problem. When the application try to send the fax I receive an "Access denied". It's strange because the same code, in a windows form runs without problems. I think there is some permission problem somewhere but I'm not able to find it. I've added full control for asp.net on the folder containing the file and for the fax server but it wasen't the right solution. I've tried to run the application applying it the "Administrator" rights, but there's no way... This is the code I use...I hope some one cuold help me. public int SendFaxDoc(String Doc) { int JobID=0; FaxServerClass faxsrv = new FaxServerClass(); faxsrv.Connect("srv"); //Pick up the new changed document and fax it out. FaxDoc faxdoc = (FaxDoc)faxsrv.CreateDocument(Doc); try { faxdoc.FaxNumber= "123456"; faxdoc.FileName=Doc; //Access is denied on this line JobID = faxdoc.Send(); } catch(Exception ex) { //Writes a log } finally { faxsrv.Disconnect(); } return JobID; }

Answers (1)