Click here to Skip to main content
15,118,573 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I am trying to Navigate from Page To Page with the click event on my main page but

gives me following error:

Argument 1: cannot convert from 'TESTTwo.Register' to 'Xamarin.Forms.Page'

My Project Named TESTTwo

What I have tried:

My Code
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Xamarin.Forms;

namespace TestTWO
public partial class MainPage :ContentPage
public MainPage()

private void Button_Clicked(object sender, EventArgs e)
Navigation.PushAsync(new Register());

My Design

<contentpage xmlns=""
="" xmlns:x="" x:class="TestTWO.MainPage">
Updated 1-Sep-21 23:29pm

1 solution

Your Register class - which you haven't shown - doesn't inherit from Xamarin.Forms.Page. You can't navigate to something that isn't a page.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900