DataTable 是存放数据的表格,而DataView 是一个视图,每一个DataTable 都有一个defaultview,你可以使用DataView 在DataTable根据你的查询条件,选择要操作的数据。
可以进行筛选。

解决方案 »

  1.   

    简单来说  DataTable中的数据是可以改动的,而DataView 中的数据是不能改的。
    就象数据库中的表和视图一样。
    这就是区别。
      

  2.   

    自己看看ms的帮助吧dv仅仅是dt的一个视图,dv中有一些属性dt没有,比如rowfilter,但是dt也能够通过其他方法简单的得到。还有比如排序等。
    customized view of a DataTable for sorting, filtering, searching, editing, and navigationAdditionally, a DataView can be customized to present a subset of data from the DataTable. This capability allows you to have two controls bound to the same DataTable, but showing different versions of the data. For example, one control may be bound to a DataView showing all of the rows in the table, while a second may be configured to display only the rows that have been deleted from the DataTable. The DataTable also has a DefaultView property which returns the default DataView for the table. For example, if you wish to create a custom view on the table, set the RowFilter on the DataView returned by the DefaultView.To create a filtered and sorted view of data, set the RowFilter and Sort properties. Then use the Item property to return a single DataRowView.You can also add and delete from the set of rows using the AddNew and Delete methods. When you use those methods, the RowStateFilter property can set to specify that only deleted rows or new rows be displayed by the DataView.我觉得主要是应用方便性的一个区别,上述的是我认为最常见的菜鸟来抛砖头了。赫赫
      

  3.   

    datatable是内存中的表,这个表可以增加,删除,update记录的,而dataview只是相当于视图,基本上是用来显示数据的
      

  4.   

    DataTable 是存放数据的表格,DataView 是一个视图。
      

  5.   

    这里一定能让你明白
    http://www.csdn.net/develop/Read_Article.asp?Id=17840
      

  6.   

    DataTable dt = new DataTable();
    DataView dv = new DataView();//u can do
    DataRow[] dr = dt.Select("myname = arli");// u can't do
    DataRow[] dr = dv.Select("myname = arli");
      

  7.   

    DataTable内存中的数据表,可以方便的将数据显示出来且独立存在
    DataView数据视图,能迅速的对用户要求的数据进行检索
      

  8.   

    多谢各位的指点,不过对于 ArLi2003(阿利,[email protected]) 举的例子
    我想可以用DataView的RowFilter来做到吧
    如 dv.RowFilter("myname=arli")
    给分,结贴! :)