title: AcquireTokenByAuthorizationCodeAsync does not complete
body: <p>Here is my code. It's been over a month I'm trying to add calendars in Outlook but nothing is working :( please help. The function <code>AcquireTokenByAuthorizationCodeAsync</code> never completes. And the <code>token.Result</code> is always null</p>
  
  <pre><code>string authority = ConfigurationManager.AppSettings["authority"];
  string clientID = ConfigurationManager.AppSettings["clientID"];
  Uri clientAppUri = new Uri(ConfigurationManager.AppSettings["clientAppUri"]);
  string serverName = ConfigurationManager.AppSettings["serverName"];
  
  var code = Request.Params["code"];
  AuthenticationContext ac = new AuthenticationContext(authority, true);
  
  ClientCredential clcred = new ClientCredential(clientid, secretkey);
  
  //ac = ac.AcquireToken(serverName, clientID, clientAppUri, PromptBehavior.Auto);
  //string to = ac.AcquireToken(serverName, clientID, clientAppUri, PromptBehavior.Auto).AccessToken;
  var token = ac.AcquireTokenByAuthorizationCodeAsync(code, new Uri("http://localhost:2694/GetAuthCode/Index/"), clcred, resource: "https://graph.microsoft.com/");
  string newtoken = token.Result.AccessToken;
  ExchangeService exchangeService = new ExchangeService(ExchangeVersion.Exchange2013);
  exchangeService.Url = new Uri("https://outlook.office365.com/" + "ews/exchange.asmx");
  exchangeService.TraceEnabled = true;
  exchangeService.TraceFlags = TraceFlags.All;
  exchangeService.Credentials = new OAuthCredentials(token.Result.AccessToken);
  exchangeService.FindFolders(WellKnownFolderName.Root, new FolderView(10));
  
  Appointment app = new Appointment(exchangeService);
  app.Subject = "";
  app.Body = "";
  app.Location = "";
  app.Start = DateTime.Now;
  app.End = DateTime.Now.AddDays(1);
  app.Save(SendInvitationsMode.SendToAllAndSaveCopy);
  </code></pre>