开发者

Rather than database, how to let datagridview bind an object?

开发者 https://www.devze.com 2023-01-30 21:42 出处:网络
Just wonder how to let datagridview bin开发者_运维问答d to object rather than database? Any example?From DataGridView.DataSource Property

Just wonder how to let datagridview bin开发者_运维问答d to object rather than database? Any example?


From DataGridView.DataSource Property

The DataGridView class supports the standard Windows Forms data-binding model. This means the data source can be of any type that implements one of the following interfaces:

  • The IList interface, including one-dimensional arrays.
  • The IListSource interface, such as the DataTable and DataSet classes.
  • The IBindingList interface, such as the BindingList class.
  • The IBindingListView interface, such as the BindingSource class.


From MSDN (DataGridView.DataSource):

The DataGridView class supports the standard Windows Forms data-binding model. This means the data source can be of any type that implements one of the following interfaces:

  • The IList interface, including one-dimensional arrays.
  • The IListSource interface, such as the DataTable and DataSet classes.
  • The IBindingList interface, such as the BindingList class.
  • The IBindingListView interface, such as the BindingSource class.

For specific examples, see the Example section and the task table at the end of this section.

0

精彩评论

暂无评论...
验证码 换一张
取 消