I have a treeview (see image attached) that does not refresh when I add an item. We use the WPF MVVM framework.
When the tree loads the first time, the treeview works perfectly. When clicking on each item, it successfully loads its sub item correctly. Now if i decide to add a sub_item to a level that I selected, For example let's say i want to add a Client vist date to treatments. So my treatment Level would be selected, I would click an add button and will create a Client Visit. After completion, I want the tree to refresh (using that load-on-demand functionality) and show me my new added Client Visit under the treatment I selected. unfortunately, this does not work. with the Load-On-Demad functionality. It seems to work only ONCE and that is when the tree is first loaded. After that it never triggers any of item_prepared, load_on_demand events until restart the application to see my changes. Please could you help in showing me, using MVVM WPF (not silverlight) how:
1) to store the item path
2) After adding an item to the treeview, refresh the tree (using load on-demand) to display the new item that was added
Thank you. This is needed so urgently. I would appreciate a fast response. Thank you again
When the tree loads the first time, the treeview works perfectly. When clicking on each item, it successfully loads its sub item correctly. Now if i decide to add a sub_item to a level that I selected, For example let's say i want to add a Client vist date to treatments. So my treatment Level would be selected, I would click an add button and will create a Client Visit. After completion, I want the tree to refresh (using that load-on-demand functionality) and show me my new added Client Visit under the treatment I selected. unfortunately, this does not work. with the Load-On-Demad functionality. It seems to work only ONCE and that is when the tree is first loaded. After that it never triggers any of item_prepared, load_on_demand events until restart the application to see my changes. Please could you help in showing me, using MVVM WPF (not silverlight) how:
1) to store the item path
2) After adding an item to the treeview, refresh the tree (using load on-demand) to display the new item that was added
Thank you. This is needed so urgently. I would appreciate a fast response. Thank you again