【发布时间】:2014-11-29 16:48:52
【问题描述】:
我正在尝试从 URL 中获取参数,但出现错误。 这是我的代码:
protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
{
base.OnNavigatedTo(e);
string str = "";
if (NavigationContext.QueryString.TryGetValue("data", out str))
{
MessageBox.Show("k");
}
}
private void aktualizuj(object sender, DateTimeValueChangedEventArgs e)
{
var btndate = sender as DatePicker;
NavigationService.Navigate(new Uri("dieta.xaml?data=" + btndate.Value.Value.Date.ToString(),UriKind.Relative));
}
我收到的错误如下:
A first chance exception of type 'System.MissingMethodException' occurred in mscorlib.ni.dll
If there is a handler for this exception, the program may be safely continued.
【问题讨论】:
标签: c# windows-phone-8 navigation