Handle the tree view's
AfterSelect[
^] event to be notified when the selection in the tree view changes. The
SelectedNode[
^] property tells you what's selected. Note that the event doesn't fire for de-selects.
The
ListBox[
^] has a ton of ways to get/set the selected items. Look at all of the properties that begin with the word
Selected
and the
SetSelected
method.