Member 12140172 Ответов: 0

Читать электронную форму обмена на C# веб-служб Exchange


im trying to read email from exchange server using the below script :

but im getting this error :

DTD is prohibited in this XML document.

i try this solution :

XmlReaderSettings xrs = new XmlReaderSettings(); xrs.ProhibitDtd = false; but error stil there .


Что я уже пробовал:

XmlReaderSettings xrs = new XmlReaderSettings();
           xrs.ProhibitDtd = false;
           ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2013);
           ServicePointManager.ServerCertificateValidationCallback = new RemoteCertificateValidationCallback(CertificateValidationCallBack);
           service.Credentials = new WebCredentials("user", "password" , "domain");
           service.UseDefaultCredentials = true;
           service.TraceEnabled = true;
           service.TraceFlags = TraceFlags.All;


           service.Url = new Uri("https://IP/");
           Folder inbox = Folder.Bind(service, WellKnownFolderName.Inbox);
           Label1.Text = inbox.DisplayName.ToString();`

0 Ответов