且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

循环datagridview中的每一行

更新时间:2023-02-05 09:51:13

您可以使用 Rows 属性循环遍历 DataGridView,例如:

You could loop through DataGridView using Rows property, like:

foreach (DataGridViewRow row in datagridviews.Rows)
{
   currQty += row.Cells["qty"].Value;
   //More code here
}