Bind a Winforms TreeView Control to a datasource?
Posted on 2009-04-22
Does the latest and greatest version of VS 2005 permit the binding of a standard Treeview control to a datasource? I have two tables, batches and labels, each batch in one table has a unique batch number and can "contain" an unlimited number of labels from the second table, and there is a foreign key on batchno between the two tables.
The tree should allow for both navigation and update, so it will be constantly changing while the user is working. What is my best approach -- XML, List Of DataObjects, DataSet, or the hard way...iterate through the dataset and repopulate the appropriate nodes, or some other approach I have not even thought of?
(NOTE: I do not know if I would be permitted to use a third party tree or not -- my boss requires special permission for that.)