ceicher

AuthenticationManager.GetCredentialAsync does not throw Exception

Discussion created by ceicher on Jul 14, 2017
Latest reply on Aug 2, 2017 by ceicher

Hi All,

 

We are using this method to generated a Credential before calling GeodatabaseSyncTask.CreateAsync().

 

AuthenticationManager.GetCredentialAsync(CredentialRequestInfo credentialRequestInfo, bool retry)

 

The way this works is that the default challenge dialog appears prompting user for userid/pwd. This works fine if the url is accessible, but in situation where the url is not accessible (e.g. internal url and device is outside the firewall), the method does not throw an exception.

 

Is there a way using this method (or similar from the SDK) to know that the url isn't accessible, e.g. via a thrown Exception?

 

Currently, all the user sees is a message in the default challenge dialog: "Previous error: An error occurred while sending the request". In VS if I enable "Compile with .NET Native tool chain" I can get a little bit more information, but I am looking for a clean solution for this.

 

Any guidance appreciated.

 

Thanks!

 

-Cory

Outcomes