Hi, I have tabcontrol,in that by pressing second tab button im adding data to third Tab Listbox.But its not get added. SecondTab function:
private void Callbutton_Click(object sender, RoutedEventArgs e)
{
tab.AddPresetmenu("CALL BUTTON");
}
ThirdTab Fucntion:
ObservableCollection<DataItem> items = new ObservableCollection<DataItem>();
public void AddPresetmenu(string pMenu)
{
items.Add(new DataItem(pMenu));
menubox.ItemsSource = items;
}
Third Tab ListBox XAML:
<ListBox x:Name="menubox" Margin="0,5,0,0" Height="244" Width="240" Background="Silver" BorderThickness="0">
</ListBox>
I think Im missing something.Please Help me.