Hello, I'm having trouble creating a menu dynamically by loading directly from a list. In my project this is as follows
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="App1.Master"
Title="Master">
<ContentPage.Content>
<TableView x:Name="tbMenu">
</TableView>
</ContentPage.Content>
</ContentPage>
tbMenu.Root = new TableRoot
{
new TableSection("Menu")
{
new TextCell
{
Text = "DESTAQUE",
Command = navigateCommad,
CommandParameter = typeof(Default)
},
new TextCell
{
Text = "ESPORTES",
Command = navigateCommad,
CommandParameter = typeof(Default)
},
new TextCell
{
Text="ENTRETENIMENTO",
Command = navigateCommad,
CommandParameter = typeof(Default)
}
}
};
I would like to populate the tableview dynamically coming directly from a Category list I tried with for and foreach more unsuccessfully could anyone give me a help?