I have this code:
public Model.Seznam<Model.Zprava> Seznam
{
get
{
return this.seznam;
}
set
{
this.seznam = value;
this.ZmenaVlastnosti("Seznam");//ChangeProperty
}
}
It's for this listbox
<ListBox HorizontalAlignment="Left" Height="328" Margin="10,10,0,0" VerticalAlignment="Top" Width="285" ItemsSource="{Binding Path=Seznam}" ItemTemplateSelector="{StaticResource VyberSablony}" />
The problem is, that I am using Seznam in main thread (adding messages, which I'Ve sent - Seznam.Add(..)
) and I need to add received messages from other thread.