Reputation: 1
My Situation put simply is that if i have a textbox, lets call it A. when i update the value in this text box it should update a label - B. when B changes then it should update another label C.
so, effectively i wish to emply binding in the form of C bind to B which binds to A.
i have tried the following but C never gets updated.
<TextBox Grid.Row="0" Name="A"/>
<Label Grid.Row="1" Name="B" Content="{Binding Text, ElementName=A, UpdateSourceTrigger=PropertyChanged}"/>
<Label Grid.Row="2" Name="C" Content="{Binding Text, ElementName=B}"/>
Upvotes: 0
Views: 612
Reputation: 56466
Try it like this:
<TextBox Grid.Row="0" Name="A"/>
<Label Grid.Row="1" Name="B" Content="{Binding Text, ElementName=A}"/>
<Label Grid.Row="2" Name="C" Content="{Binding Content, ElementName=B}"/>
You have to bind to the Content property.
Upvotes: 2