facebook-c#-sdk FacebookUriMapper [英] facebook-c#-sdk FacebookUriMapper
问题描述
我正努力遵循适用于.NET的Facebook SDK的配置教程.
I'm tring to follow the Configuring tutorial of the Facebook SDK for .NET.
但是当我添加代码的RootFrame.UriMapper = new FacebookUriMapper();
行时,NavigationService
似乎停止工作.
But when I add the RootFrame.UriMapper = new FacebookUriMapper();
line of code the NavigationService
seems stop to work.
应用程序启动正常,但在初始化应用程序页面上的按钮"中插入的命令NavigationService.Navigate(new Uri("/Views/LoginPage.xaml", UriKind.Relative));
不起作用.相同按钮上的其他命令,例如MessageBox.Show
都可以正常工作.
The app start's fine but the command NavigationService.Navigate(new Uri("/Views/LoginPage.xaml", UriKind.Relative));
inserted in a Button on init app page don't work. Other commands on same button like a MessageBox.Show
works fine.
感谢您提供的任何帮助.
Thank you for any help you can provide.
推荐答案
Facebook.Client SDK中的文件FacebookUriMapper
有一个错误.通过调试器查看时,它不会重定向到目标页面,而是切换回Facebook.xml
中的默认RedirectUri
.在计算机中克隆存储库,打开WP8解决方案,还原所需的Nuget
软件包.现在,打开FacebookUriMapper.cs
文件,修改最后一个else
块以返回uri
.生成并将其用作您的参考程序集. NavigationService
之后绝对可以正常工作.
The file FacebookUriMapper
in the Facebook.Client SDK has a bug. When looking via debugger, it doesn't redirect to the target page, but switches back to the default RedirectUri
in Facebook.xml
. Clone the repository in your computer, open the WP8 solution, restore required Nuget
packages. Now, open FacebookUriMapper.cs
file, modify the last else
block to return uri
. Build and use this as your referenced assembly. NavigationService
works absolutely fine after this.
这篇关于facebook-c#-sdk FacebookUriMapper的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!