Hi,
I have tabbed page with navigation bar. In that page I am conditionally showing & hiding the "option" toolbar item. I have added my code below.
ToolbarItem optionItem = new ToolbarItem ();
optionItem.Name = "Options";
optionItem.Command = new Command (async () => {
ShowOptions(_selectedContactIds.ToArray());
});
if (_selectedContactIds.Count >= 1) {
if (this.ToolbarItems.Count != 2) {
this.ToolbarItems.Add (optionItem);
}
} else {
if(this.ToolbarItems.Count >= 2)
{
this.ToolbarItems.RemoveAt (1);
}
}
I was able to show & hide my toolbar item based on selected listview items before upgrading to 1.2.3 pre 3. But after that this is not working. I have same logic in another page also there its working fine, but that's not a tabbed page. I don't know what made its not working in tabbed page.
I was very doubtful about this strange issue. In order to clear that, I again downgraded to 1.2.2 pre 2 and it worked fine. Now I am sure there is some bug in 1.2.3 pre 3. How to fix it?