使用 Azure 移动服务进行身份验证
本文关键字:身份验证 服务 Azure 移动 使用 | 更新日期: 2023-09-27 18:31:40
我为Windows 10构建了一个通用应用程序。在我的应用程序中,我正在使用Azure移动服务进行身份验证(Facebook,Google等)。
// Define a member variable for storing the signed-in user.
private MobileServiceUser user;
// Define a method that performs the authentication process
// using a Facebook sign-in.
private async System.Threading.Tasks.Task<bool> AuthenticateAsync()
{
string message;
bool success = false;
try
{
// Change 'MobileService' to the name of your MobileServiceClient instance.
// Sign-in using Facebook authentication.
user = await App.MobileService
.LoginAsync(MobileServiceAuthenticationProvider.Facebook);
message =
string.Format("You are now signed in - {0}", user.UserId);
success = true;
}
catch (InvalidOperationException)
{
message = "You must log in. Login Required";
}
var dialog = new MessageDialog(message);
dialog.Commands.Add(new UICommand("OK"));
await dialog.ShowAsync();
return success;
}
我的登录窗口有问题。在低分辨率下,我得到了这个窗口。
低分辨率的登录窗口(屏幕截图)。
但是在高分辨率下,我得到了这个窗口。
高分辨率登录窗口(屏幕截图)。
如何针对不同的分辨率缩放此网页?也许我可以访问网络视图?
提前谢谢。
据我所知,您无法访问Web视图,因为它是操作系统级别,但是仍然可以访问大网页。