Results 1 to 3 of 3

Thread: DataBound Controls and DataTable

  1. #1

    Thread Starter
    Addicted Member MasterBlaster's Avatar
    Join Date
    Jul 2002
    Location
    Seattle
    Posts
    196

    DataBound Controls and DataTable

    Hi All, got a couple noob data binding questions.

    Say I have a DataTable bound to a datagrid. Do changes made to the data in the datagrid only modify the data in my data table object, not the database?

    If this is the case. Is there a way to track what records in the data table have been modified, added or deleted since the data table was first created and bound to the datagrid?

    thnx.
    "And most of the evils of society can, in fact, be cured through information. We have a society that has been disinformed and based on the disinformation has made irrational choices. And that's what I mean by 'ignorance.' People, who ordinarily might be smart, are deprived of the data by which to make a rational decision, don't have the data to do it."
    Frank Zappa

  2. #2
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    One way is assigning your old datatable to a new datatable that has only changes . Like this :

    Code:
    //YourDataTable = a datatable that has data you are working on .
    DataTable NewDT=new DataTable ();
    NewDT=YourDataTable.GetChanges();

  3. #3

    Thread Starter
    Addicted Member MasterBlaster's Avatar
    Join Date
    Jul 2002
    Location
    Seattle
    Posts
    196
    Exactly what I was looking for I think. thanks.
    "And most of the evils of society can, in fact, be cured through information. We have a society that has been disinformed and based on the disinformation has made irrational choices. And that's what I mean by 'ignorance.' People, who ordinarily might be smart, are deprived of the data by which to make a rational decision, don't have the data to do it."
    Frank Zappa

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width