Not necessarily simpler, but there is a link here that explains the process with more detail on CodeProject. (Article by
Arindam Sinha)
http://www.codeproject.com/KB/grid/SearchSortBindingList.aspxIn this selection, the binding is done not from a datasource, but from a databindingsource object. It is quite similar to the code currently in place (above); however, the difference is that he uses a binding source for search criteria, for search, for the master list and another for a result that is similar to a foreign key. The article is clear, but you may want to download the code and walk through it to get a feel for the way it works.
I also discovered that the class built to bind to the (listbox in my case) combobox, could not be persuaded to be a data object until it was placed in a folder. Thus to get the dataobject required for the binding I had to perform five extra steps:
1) add a folder to the project and move the class for binding to the folder
2) add in the BaseBindingList<T> : BindingList<T> class listed in Arindam Sinda's article (above) - Many thanks Arindam
3) create a public collection of the class I wish to bind to thus for a class such as person, one would create a class called people thus:
public class People BaseBindingList<People>{} - add this class to the folder as well.
4) add a bindingsource object to your form from the ToolBox (this will allow you to bind the List<T> data object with the listbox or combobox (or datagrid... etc)
5) use the data wizard to associate the bindingsource with the List<T> (using the example above - it would be the object People).
Once this is in place, that is,the folder as a data object connected to the bindingsource object on your form;access the properties of your listbox or combobox and select the data object as the data source. At that point, the IDE does most of what is required... like setting the datamember and datavalue for the list - simply click the listbox/combobox datasource dropdown in the properties of the listbox/combobox and select the bindingsource object.