【发布时间】:2014-11-28 23:37:01
【问题描述】:
我有一个页面 MainPage.xaml,它有一个文本框和一个用于 page1.xaml 转换的按钮,在我的页面 mainpage.cs 中我有一个方法:
private void Button_Click(object sender, RoutedEventArgs e)
{
string newUrl = "/Page1.xaml?text=" + textoInput.Text;
NavigationService.Navigate(new Uri(newUrl, UriKind.Relative));
}
在我的 Page1.xaml 中,我有一个文本块,它将是放置在 MainPage.xaml 文本框中的文本。 在我的 Page1.cs 我有一个方法:
string textBoxValue = "";
protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
{
base.OnNavigatedTo(e);
//Retrieve the value passed during page navigation
NavigationContext.QueryString.TryGetValue("text", out textBoxValue);
textBlockTexto.Text = textBoxValue;
}
我的问题是如何让我的文本块 (text.BlockTexto.Text) 无限闪烁
谢谢
【问题讨论】:
标签: c# xaml windows-phone-8