for (int i = 0; i < maxrow1; i++)
{
if (clmax1 < double.Parse(dataGridView1.Rows[i].Cells[2].Value.ToString()))
{
clmax1 = double.Parse(dataGridView1.Rows[i].Cells[2].Value.ToString());
clmax.Text = clmax1.ToString();
double alphamax1 = double.Parse(dataGridView1.Rows[i].Cells[1].Value.ToString());
alphaclmax.Text = alphamax1.ToString();
}
}
此代码在Windows窗体应用程序上有效,但我想读取WPF上的所有行和列值。