I have an EmployeeUltraGrid that is bound to IEnumerable(Of Employee).
I want to add a row programatically. How can I do this?
In the past, my data sources have always been DataTables and I would just add a row to the DataTable.
Not sure what do to now that the data source is IEnumerable(of Employee).
Thanks for amy help.
Hi,
I don't thiink you can. The IEnerumable interface doesn't support adding as far as I know. In fact, I'm surprised you can even bind this to the grid. The grid requires the data source to be an IList or IBindingList, and I'm pretty sure you need an IBindingList in order to add rows through the grid.
If you are using Visual Studio 2005 or higher, you could use the BindingList<> generic type. Or you could use an UltraDataSource as the data source of your grid in any version.