Jak można wybrać inny datownik oznaczający pole w źródle powiązania danych? chciałbym mieć 2 różne DataTemplatesSzablony danych warunkowych w WPF
<DataTemplate x:Key="DataTemplateLabel">
<Label Width="60" Height="25" Background="Red">
<TextBlock Text="{Binding Path=Name}"/>
</Label>
</DataTemplate>
<DataTemplate x:Key="DataTemplateTxtBox">
<TextBox Width="60" Height="25" Background="Red" Text="{Binding Path=Text}"/>
</DataTemplate>
if (isText) Następnie użyj DataTemplateTxtBox ELSE używać DataTemplateLabel) Czy jest to możliwe? Dzięki.