I’m trying to troubleshoot my ComboBox. It’s declared like this:
<ComboBox x:Name="SampleComboBox" ItemsSource="{Binding Path=SelectedSample.SampleName}" />
SelectedSample returns a custom object, that has a property of SampleName that is a string type. When I check the value while in debug mode, I see the correct text, “Sample 1”. But when it appears in the ComboBox, it looks like this:
S
a
m
p
l
e
1
Not sure why it does that because when I create a normal List someProperty, and bind to that property, the data shows up normal.
TestData 1
TestData 2
TestData 3
...
Any thoughts? Thanks.
is treated as IEnumerable and you get an array of characters
Its an ItemSource property so you need to provide
IEnumerable<Something>there