GetChanges() problem if the rows are grouped

5 replies. Last post: November 6, 2009 1:07 AM by Handy Surya
Tags :
  • New Discussion
  • New Question
  • New Product Feedback
I have a problem with GetChanges() if the rows are grouped. Please have a look on attached pictures and sample.
Following Code (DelChanges[i].Row.GetCell()) works in first group only!
Have I forgotten anything?
var DelChanges = grd.GetChanges("Deleted");
for (var i in DelChanges) {
    if (DelChanges[i].Row.GetCell("Dependencies").Value > 0) {
        if (DependenciesText.length > 0)
            MessageQuantity = 2;
        else
            MessageQuantity = 1;
        DependenciesText += "\n - " + DelChanges[i].Row.GetCell("CustomerID").Text + " | " + DelChanges[i].Row.GetCell("CompanyName").Text + " | " + DelChanges[i].Row.GetCell("ContactName").Text + " | " + DelChanges[i].Row.GetCell("ContactTitle").Text;
        DelChanges[i].Row.UndoChanges();
    }
}

Please try my sample.

  1. Change ConnectionString and run sample
  2. Delete a row in first group
  3. Accept all Changes (-> Messagebox)
  4. Delete a row in second group
  5. Accept all Changes (-> Error)
All times are GMT -5. The time now is 6:33 PM.
Previous Next