PrepAway - Latest Free Exam Questions & Answers

Which code segment should you recommend for the main page?

You are designing a Windows Phone 7 application that contains a Pivot page.
The Pivot page contains the following code.
Protected Overrides Sub OnNavigatedTo(
ByVal e As System.Windows.Navigation.NavigationEventArgs) Dim index As Integer =
Convert.ToInt32(NavigationContext.QueryString(“index”)) pivot1.SelectedIndex = index
MyBase.OnNavigatedTo(e)
End Sub
You need to ensure that navigation between the main page and the Pivot page works without runtime errors. Which code segment should you recommend for the main page?

PrepAway - Latest Free Exam Questions & Answers

A.
NavigationService.Navigate(
New Uri(“/PivotPage1.xaml?index=0”, UriKind.Absolute))

B.
NavigationService.Navigate(
New Uri(“/PivotPage1.xaml?index=0”, UriKind.Relative)) NavigationContext.QueryString.Add(“index”, “0”)

C.
NavigationService.Navigate(
New Uri(“/PivotPage1.xaml”, UriKind.RelativeOrAbsolute)) NavigationContext.QueryString.Add(“index”, “0”)

D.
NavigationService.Navigate(
New Uri(“/PivotPage1.xaml”, UriKind.Relative))


Leave a Reply