I'm binding a text box to a textblock, but it is not updated when I paste something using the context menu.
Following there is the XAML code for element binding:
<uc:CustomTextBox x:Name="txtBoxLastName"
Grid.Row="3"
Grid.Column="1"
Width="80"
Height="25"
HorizontalAlignment="Left" />
<TextBlock Grid.Row="4"
Grid.Column="1"
Width="100"
Height="100"
Text="{Binding Text,
ElementName=txtBoxLastName}" />
Context menu paste code:
this.SelectedText = Clipboard.GetText();
What's wrong with this code? Is there any other way to do the same ?
Regards.