1
votes

How can I disable the xamarin icon in the navigation page bar and set the title?

2

2 Answers

1
votes

You can use this to remove the icon.

ActionBar.SetIcon(Android.Resource.Color.Transparent);

And to set the title you can use the code in C#

this.Title="mypage"

or for Xaml put the below attribute in the ContentPage node

Title="mypage"
1
votes

We can access the ActionBar Icon and set it to transparent in the Android Project, Code:

protected override void OnCreate (Bundle bundle)
{
    base.OnCreate (bundle);
    global::Xamarin.Forms.Forms.Init (this, bundle);
    LoadApplication (new App ());
    this.ActionBar.SetIcon ((int)Android.Graphics.Color.Transparent));
}

Page has a title property that can be set. You can do it in the constructor something like this:

 this.Title = "my page";