Binding an Element to a Control Property (string)

Posted by 108980470541437452574 on Stack Overflow See other posts from Stack Overflow or by 108980470541437452574
Published on 2010-05-28T21:05:50Z Indexed on 2010/05/28 21:12 UTC
Read the original article Hit count: 144

Filed under:

so, i've found a way to bind a label to a property on current Control

i give it a name:

<UserControl x:Class="WpfGridtest.GridControl" x:Name="GridControlControl1">

and than bind to property of this control:

<Label Content="{Binding ElementName=GridControlControl1, Path=Filter}"></Label>

I can see the default value i put in that property.

I am guessing that this isn't working because i am binding to String property which doesn't implement INotifyPropertyChanged??

is there some other type i should be using for this property instead of String auto notify my label of changes, or am i going about this the wrong way?

© Stack Overflow or respective owner

Related posts about wpf