如何使用VB代码在Silverlight中导航到注释页面? [英] How to navigate to anoter page in Silverlight using VB code?
本文介绍了如何使用VB代码在Silverlight中导航到注释页面?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有两个Silverlight页面-> Mainpage.xaml和page2.xaml.
MainPage.xaml上有一个按钮(btn1),当我单击此按钮时,我想导航到page2.xaml.我该怎么做(使用VB代码)?
I have two silverlight pages -> Mainpage.xaml and page2.xaml.
There is a button (btn1) on MainPage.xaml and when i click this button, i want to navigate to page2.xaml. How do i do this (using VB code)?
推荐答案
做到这一点的标准方法是使用RootVisual属性:
The standard way of doing this is to use the RootVisual property:
App.Current.RootVisual = New MyPage
如果您使用的是Silverlight 3.0,则应查看SL导航
If you are using Silverlight 3.0, you should be looking at the SL navigational framework.
这篇关于如何使用VB代码在Silverlight中导航到注释页面?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文