Click here to Skip to main content
15,890,845 members
Please Sign up or sign in to vote.
2.50/5 (2 votes)
See more:
Hello,

I have a WPF TreeView bound to an XmlDataProvider. When I add a new child the treeview is automatically updated:

xmldocument.SelectSingleNode("SW/AnyJobs").AppendChild(newChild);

However, when i change an attribute which is bound to a converter for the TreeView Header, no update occurs:

xmldocument.SelectSingleNode("SW/AnyJobs").LastChild.SetAttribute("Name", "1234");

Does anyone have a suggestion?

Thanks in advance!

What I have tried:

I have tried a number of things without success...
Posted
Updated 25-Apr-16 2:48am
Comments
Herman<T>.Instance 22-Apr-16 3:27am    
Do you Notify the Change in the Viewmodel or Model?
VR Karthikeyan 22-Apr-16 3:44am    
Just implement INotifyPropertyChanged interface in class of child object for Name properties and other properties that you want to notify the change in UI.

1 solution

I have tried this - this doesn't work as the binding is to the XmlElement itself and not "Name"
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900