Could you help me with this exception error in xamarin, I can not find the error, I'm doing a MasterDetailPage, the other pages work invividually including the menu
This is where the error marks me
private void InitializeComponent()
{
global::Xamarin.Forms.Xaml.Extensions.LoadFromXaml(this, typeof(MasterPage));
Navigator = global::Xamarin.Forms.NameScopeExtensions.FindByName<global::Xamarin.Forms.NavigationPage>(this, "Navigator");
}
this is my code in xaml
*<?xml version="1.0" encoding="utf-8" ?>
<MasterDetailPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:pages="clr-namespace:ProyectoAnimalCared.Pages;assembly=ProyectoAnimalCared"
x:Class="ProyectoAnimalCared.Pages.MasterPage">
<MasterDetailPage.Master>
<pages:MenuPage></pages:MenuPage>
</MasterDetailPage.Master>
<MasterDetailPage.Detail>
<NavigationPage x:Name="Navigator"
BarBackgroundColor="{StaticResource MainColor}">
<x:Arguments>
<pages:MainPage>
</pages:MainPage>
</x:Arguments>
</NavigationPage>
</MasterDetailPage.Detail>
</MasterDetailPage>*
namespace ProyectoAnimalCared.Pages
{
public partial class MasterPage : MasterDetailPage
{
public MasterPage()
{
InitializeComponent();
}
protected override void OnAppearing()
{
base.OnAppearing();
App.Master = this;
App.Navigator = this.Navigator;
}
}