初次登录后,用户必须始终确认权限-help? [英] User must always confirm permissions after initial login -help?
问题描述
您好,
我的Windows Phone 8应用每次加载主页时都会调用authClient.LoginAsync(...),这意味着用户必须始终确认范围每次应用重启时应用都需要。即使在通过开发人员文档搜索
之后,我也想不到任何其他登录方式。有没有办法让用户登录?我有一个"wl.signin"范围,但这只是让用户不必输入他的密码,他仍然必须确认权限。
任何帮助将不胜感激。
//登录
Console.WriteLine("登录...");
如果(loginResult == null)
{
loginResult =
await authClient.LoginAsync(new string [] {" wl.basic"," wl.skydrive"," wl.skydrive_update"," wl.signin"});
this.session = authClient.Session;
this.connectClient = new LiveConnectClient(this.session);
}
//现在我们已经登录了,我们可以做的事情如果(loginResult.Status == LiveConnectSessionStatus.Connected)
{
      //代码在这里
} <
class
你试过包括" wl.offline_access"范围&NBSP;?
Hello,
My Windows Phone 8 app calls authClient.LoginAsync(...) every time the main page loads, which means that the user must always confirm the scopes required by the app every time the app restarts. I can not think of any other way to log in, even after searching through the developer documents. Is there any way to keep a user logged in? I have a "wl.signin" scope, but that just keeps the user from having to put in his password, and he must still confirm the permissions.
Any help would be greatly appreciated.
//log in
Console.WriteLine("Logging in...");
if (loginResult == null)
{
loginResult =
await authClient.LoginAsync(new string[]{ "wl.basic", "wl.skydrive", "wl.skydrive_update", "wl.signin" });
this.session = authClient.Session;
this.connectClient = new LiveConnectClient(this.session);
}
//Now that we're logged in, we can do stuff
if (loginResult.Status == LiveConnectSessionStatus.Connected)
{
//CODE HERE
}
Have you tried including the "wl.offline_access" scope?
这篇关于初次登录后,用户必须始终确认权限-help?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!