【问题标题】:How to navigate from one xaml page to another xaml page in visual studio 2013 for windows phone 8.1 app?如何在 Visual Studio 2013 for windows phone 8.1 应用程序中从一个 xaml 页面导航到另一个 xaml 页面?
【发布时间】:2015-03-28 22:15:27
【问题描述】:
public MainPage()
    {

        this.InitializeComponent();

        NavigationService.Navigate(new Uri("/SpillGuard.xaml", UriKind.Relative));

    }

错误提示导航服务在当前上下文中不存在。

【问题讨论】:

标签: visual-studio-2013 windows-phone-8.1


【解决方案1】:

就像 Romansz 说的,下次尝试用力搜索。

NavigationService 不存在,因为它仅用于 Windows Phone Silverlight 应用程序。使用Frame.Navigate()

Frame.Navigate(typeof(YourPage), optionalParameter);

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多