Finding modified rows count in datagridview
hey guys..how can i find how many rows are modified by the user in my datagridview?
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Jean PaulRank #32 · 38.5K reputationPosted Feb 7, 2011, 2:03 AM EST
But I can provide one lengthy solution:
On the DataGridView CellEndEdit, use the DataGridViewCellEventArgs object
to get the edited row index. You can push the rowindex to a list ensuring no duplicates
The total of listcount will provide number of changed rows.
Erdinc Kolukisa109 reputationPosted Feb 7, 2011, 2:41 AM EST
Jean PaulRank #32 · 38.5K reputationPosted Feb 7, 2011, 3:07 AM EST
Sam HobbsRank #107 · 20.5K reputationPosted Feb 7, 2011, 6:48 PM EST
Erdinc Kolukisa109 reputationPosted Feb 7, 2011, 11:49 PM EST
Jean PaulRank #32 · 38.5K reputationPosted Feb 8, 2011, 12:22 AM EST
controls/methodology are you using?
In my applications I use DataGridView customized with IList bound to it.
Sam HobbsRank #107 · 20.5K reputationPosted Feb 8, 2011, 7:15 AM EST