Terms.xml ----
<?xml version="1.0" encoding="utf-8" ?>
<Terms>
<Item Name="Muddy" Surname="Waters" />
<Item Name="Roy" Surname="Buchanan" />
</Terms>
-----------------
xaml ---------
<Window.Resources>
<XmlDataProvider
x:Key="XmlData"
Source="d:\Terms.xml"
XPath="Terms" />
</Window.Resources>
<Grid>
<ComboBox
x:Name="ComboBox1"
IsEditable="True"
ItemsSource="{Binding Source={StaticResource XmlData}, XPath=./Item}"
DisplayMemberPath="@Name"
SelectionChanged="ComboBox1_SelectionChanged"
Width="240"
Grid.Column="0"
Grid.Row="0"
Height="25"
HorizontalAlignment="Left"
VerticalAlignment="Stretch"
Margin="20,50,0,0"/>
<TextBox
x:Name="TextBox1"
Width="240"
Height="25"
Grid.Column="0"
Grid.Row="0"
HorizontalAlignment="Left"
VerticalAlignment="Bottom"
Margin="20,70,0,80" />
</Grid>
-------------------------------------------------
I'd like to make TextBox1 display the Surname of the corresponding Name once selected in Combobox1.
Any suggestions?