Hi,
I am using the below method (using Web Service) to resolve an User in Infopath Form.
string role = string.Empty;
XPathNavigator nav = this.DataSources[DATA_USERROLESRESOLVE].CreateNavigator();
nav.SelectSingleNode(XPATH_USERQ, this.NamespaceManager).SetValue(GetCurrentUsername());
this.DataConnections[DATA_USERROLESRESOLVE].Execute(); //I think this is the point of error
XPathNavigator node;
node = nav.SelectSingleNode(XPATH_USERROLESRESOLVE + string.Format(XPATH_USERROLESUFFIX, ROLE_GROUP), this.NamespaceManager);
But when I open the InfoPath form, and call the above method to resolve an user, I am getting below error message. The code is working fine in Local as usual, but in remote servers. Please help to fix this. Thanks in Advance.
Details of Error
IsUserInGroupWeb <br>System.Net.WebException: The remote server returned an error: (401) Unauthorized. --->