I've just start new Xamarin.Forms project and I don't know what I'm doing wrong. In my App.cs file I'm trying to set my TestPage(I've created TestPage by Add->New Item-> BlankPage) as Main Page but i'm geting this error "Severity Code Description Project File Line Suppression State Error CS0029 Cannot implicitly convert type 'Paternity_Test.TestPage' to 'Xamarin.Forms.Page'"
My TesPage.xaml.cs
namespace Paternity_Test
{
public partial class TestPage : Xamarin.Forms.Page
{
public TestPage()
{
this.InitializeComponent();
}
}
}
And My App.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xamarin.Forms;
namespace Paternity_Test
{
public class App : Application
{
public App ()
{
MainPage = new TestPage(); //here Im geting this error
}
protected override void OnStart ()
{
// Handle when your app starts
}
protected override void OnSleep ()
{
// Handle when your app sleeps
}
protected override void OnResume ()
{
// Handle when your app resumes
}
}
}
What I'm doing wrong?
.XAML
look like for that page? Just the top three lines will do – SushiHangover