Skip to content

Instantly share code, notes, and snippets.

@jimmgarrido jimmgarrido/fixed page.cs Secret
Created Jul 6, 2017

Embed
What would you like to do?
b57965
public partial class MainPage : ContentPage
{
Entry entry;
StackLayout stacklayout;
Button nextpage;
public MainPage()
{
InitializeComponent();
entry = new Entry();
stacklayout = new StackLayout();
nextpage = new Button() { Text="Next Page"};
nextpage.Clicked += Nextpage_Clicked;
stacklayout.Children.Add(nextpage);
this.Content = stacklayout;
}
protected override void OnAppearing()
{
base.OnAppearing();
stacklayout.Children.Insert(0, entry);
}
private void Nextpage_Clicked(object sender, EventArgs e)
{
SecondPage secondpage = new SecondPage(entry);
Navigation.PushAsync(secondpage);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.