Binding Property Of Control From Other Control Using XAML in WPF
Nov
07
Hello, today i am going to tell you how to bind "Content" property of label to the textbox "Text" property.........
hmmmmm, i know that you are thinking what new in this , this can be achieved using simple coding but in this post i am going to tell you how can you achieve this using XAML(a strong part of wpf) , this is a new way of binding , so plz take a look at this post.....
Well , lets do it with an example....... what we do is that we enter some text in textbox and at the same time the content of the label changes.. to achieve this use this part of code to set in content property of label in xaml window :-
<Label Name="lbl1" Content="{Binding ElementName=textbox1, Path=Text}"></Label>
here, ElementName tells -- to which control should the label control bind and the Path tells -- to which property it is binded
Hope, you all enjoy this and understood the motive of posting this post...... :-p
Wednesday, November 07, 2012 | Labels: Wpf |
- Solved - "Are You Missing An Assembly Reference Error in Visual Studio"
- Binding Property Of Control From Other Control Using XAML in WPF
- Check DropDown List contains a value in Asp.net ????
- How to place cursor at the end and begining of the text in textbox??????
- How To Get Facebook Profile ID
- How To Create Disk Partition on Windows7
- Top 10 Tips To Improve System Speed
Total Pageviews
1082