Are you speaking here of an end-user clicking on a Column Header (i.e., the text in the column label area at the top), or are you speaking of an end-user clicking on an item in a Column, and from the item selected/clicked deducing the Column Header text ?
"It is the mark of an educated mind to be able to entertain a thought without accepting it." Aristotle
1. This has nothing to do with C#
2. Googling would reveal a plethora of hits
3. Please try to avoid text speak. It only serves to annoy people. There are so many amazing letters in the English language, like the letter y. It's a shame to ignore them.
It is a server based application suited for development teams. It is not a project as such. Once you have TFS installed you can use it for project management, source control, continuous integration and a whole lot more.
Binding handles notification by updating the property which has been notified as changed. Or, if you want to update every property, you can notify on null.
Also, you shouldn't use name prefixes like that in .Net, particularly for public members. It should be class MyData, public string Text, etc.
And finally, the mObj you're creating in MainWindow and assigning the Text property of is not the same as the one in the resources. Instead of doing
mObj = new CMyData();
... you need to assign the local mObj (which can and should be private) out of the page resources, which I can't remember how to do off the top of my head. Hopefully a XAML/WPF expert will wander by shortly.
mObj is declared in the XAML, so in code, you need to retrieve the instance that's in the resources, instead of creating a new one. As I say I can't remember what the expression is exactly. It's something like mObj = Page.Resources["mObj"] but I know it isn't that simple. Someone who works with this stuff on a regular basis should come around here in a little while.
Using the DataContext property on a parent element is useful when you are binding multiple properties to the same source. However, sometimes it may be more appropriate to specify the binding source on individual binding declarations. For the previous example, instead of using the DataContext property, you can specify the binding source by setting the Source property directly on the binding declaration of the button, as in the following example:
Now it works
Last Visit: 31-Dec-99 19:00 Last Update: 7-Dec-23 13:31