Back to the original question:
I think this was properly answered in post 10. I can't see how treeview focus has anything to do with this.
hehe ok let me try again.... When you select a name in the treeview list it changes the closed folder, by the name in the treeview node, to an open folder and opens an MDI child form in the right side of the screen.
When I select a second client from the treeview the same thing occures as planned, the previous node graphic changes from an open folder to a closed folder, this works fine.
Now here's where everything changes.
If I select a different already opened child form on the right side of the screen the highlighted child node doesn't change. If I have 2 open children say, one for Adam T. Davis and another for Aziz Michael, and The last one I had opened was Aziz Michael. The Node in the treeview with his name would be highlighted still and focus would be on the newly created child form with his name in the title.
I then decide to click the child form for Adam T. Davis, not closing any forms, just changing focus from one child form to another. The Treeview selection does not change. The node for Aziz Michael would still be open even though the child form I'm now viewing is for Adam T. Davis.
I need a way for when I select a child form, I can have the Treeview node change to reflect which child form I'm now working with. When I click on Adam T. Davis I want the Treeview node to have the open folder for Adam T. Davis not Aziz Michael.
The other problem with this being the way it currently is, is when I change focus to a different child form from say Adam T. Davis to Aziz Michael's form, If I then close the Child for Adam T. Davis the Node for Adam T. Davis is still in the selected state and I cannot reopen a child for that unless I click a different node in my Treeview first, then click the node for Adam T. Davis again to reopen a child form.
It should be as easy as clicking a node to open the child form. When you close the child it deselects the treeview node and basically everything is resetted so I can reclick that node and reopen the form if I want.
Agaon this functionality works when just selecting from the treeview control but if change focus with any open children forms and close any of those the treeview control doesn't know this and isn't updated to reflect the changes.
If you'll notice in my screenshot the child form for Carl Broom has focus but the treeview node for Adam T. Davis is the one with the open folder. It should be the node for Carl Broom that is open.
I need a way to manipulate the treeview nodes when I change focus on the child forms.