![](/img/trans.png)
[英]How to navigate to one Panorama item (pane) to another from selecting a button?
[英]How to navigate to specified panorama item from another page
我有MainPage.xaml
和PanoramaPage1.xaml
。
如何從MainPage
導航到PanoramaPage
Item1
或Item2
?
例如: Button1->Item1
和Button2->Item2
您可以使用標准的navitaion:
this.NavigationService.Navigate(new Uri("PanoramaPage1.xaml?buttonid=button1",UriKind.Relative));
在對象變量中傳遞您的目標,然后在panomarama頁面中處理:
protected override void OnNavigatedTo(NavigationEventArgs e)
{
if ( this.NavigationContext.QueryString.ContainsKey( "buttonid" )
{
string buttonid = this.NavigationContext.QueryString[ "buttonid" ];
}
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.