Hi,
I have written the following code to login into the Exchange Server but I got the error "The Autodiscover service couldn't be
located"
excusername = "UserName";
excpassword = "Password";
excdomain = "SomeDomain";
excurl = "ConnectionURL";
excemail = UserName@domain.com;
ExchangeService _exch = new ExchangeService(ExchangeVersion.Exchange2010_SP1);
_exch.Credentials = new WebCredentials(excusername, excpassword, excdomain);
_exch.Url = new System.Uri(@"http://" + excurl);
_exch.AutodiscoverUrl(excemail);
When I execute this code, I got the exception in below line
_exch.AutodiscoverUrl(excemail) ;
Stating as "The Autodiscover service couldn't be located". So, please tell us the solution as soon as possible.
Regards
Nishant