//判断当前用户是否重复。 private User IsExistUser(string appId, string personId) { User _user = null; try { PrivilegeService _proxy = Common.Util.CreateProxy(); using (_proxy as IDisposable) { _user = _proxy.GetUserByPersonId(appId, personId); } } catch (Exception e) { MessageBox.Show(e.Message, "提示"); return(null); } return(_user); }