我试过用MyObject[] 和 ArrayList , 但在DataGrid中只能编辑,不能添加。
要怎么实现呢?是要实现什么Interface吗?

解决方案 »

  1.   

    上面写错了
    AllowAddNew = True
      

  2.   

    谢谢  44404(杨雪) 。是DataGrid.AllowAddNew = true 吗? 可是我找不到这个属性呀!
      

  3.   

    呵呵 我就是不想用DataView 和 DataTable。 
    我是用DataReader 检索数据,然后将数据放入我自己写的class. 在用这个class的数组,或classList :ArrayList,作为DataSource.没用DataSet.
      

  4.   

    you need to use IBindingList/IEditableObject, see
    http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnadvnet/html/vbnet02252003.asp
      

  5.   

    saucer(思归) : 谢谢了。 
    如果我没记错的话,上次我也有个问题是你帮我解决的。 再次感谢!:)