ArrayList - DataGrid binding

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jordan

    ArrayList - DataGrid binding

    After binding an arraylist to a datagrid, is it possible to allow the
    user to add and delete new rows on the datagrid just as they would if
    a datatable were bound to the control? I have tried to implement some
    interfaces but nothing has been successful so far, thanks in advance,
    Jordan
  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: ArrayList - DataGrid binding

    Jordan,

    Unfortunately, no. You will have to bind the data grid to a class that
    implements IBindingList. This is what will allow you to add new rows/delete
    rows, and see changes to items in the list. You will have to wrap your
    ArrayList with something that implements this.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Jordan" <jblanchet@selk irkfinancial.co m> wrote in message
    news:d36a6d76.0 311130856.2c5e2 692@posting.goo gle.com...[color=blue]
    > After binding an arraylist to a datagrid, is it possible to allow the
    > user to add and delete new rows on the datagrid just as they would if
    > a datatable were bound to the control? I have tried to implement some
    > interfaces but nothing has been successful so far, thanks in advance,
    > Jordan[/color]


    Comment

    Working...