I have a TreeView population routine that is rather lengthy and have decided
to use a BackgroundWorker to run it in a background thread. Since I am
unable to access my TreeView control directly in the BackgroundWorker, I
create a new instance of a TreeView class in the background thread, populate
it, and then return it to my main thread through the e.Result
DoWorkEventArgs. All of this works fine.
My question is how do I assign this populated TreeView class instance to the
TreeView Control on my form? When I set my TreeView control to the populated
TreeView class instance nothing is displayed in the control. I have verified
that the nodes in the TreeView contain data. Any suggestion that anyone
might have would be appreciated.