ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010_SP1)
{
Credentials = new WebCredentials("usrname", "pass#1234")
};
//to add logic for itemview
service.AutodiscoverUrl("emailaddress@test.com");
When I'm running the above code in my application hosted on iis , it is throwing an error 'autodiscover service couldn't be located'.
But when I am running the same on visual studio development server it is working fine.
How to solve this issue?