What is the Response.Redirect equivalent in Silverlight?

烈酒焚心 提交于 2020-01-14 10:11:44

问题


I need to go another page or url. What is the response.redirect in silverlight?


回答1:


If you want navigate to another page of Silverlight Navigation Application:

NavigationContext.Navigate( new Uri( "/Views/Home.xaml", UriKind.Relative ) );

where NavigationContext - Page property

If you want navigate to another url:

System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("http://stackoverflow.com"), "_blank");


来源:https://stackoverflow.com/questions/7378037/what-is-the-response-redirect-equivalent-in-silverlight

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!