如何获得中EmptyDataTemplate的控件的值
((TextBox)((Table)GridView1.Controls[0]).Rows[0].FindControl("BankCard")).Text;
((DropDownList)((Table)GridView1.Controls[0]).Rows[0].FindControl("DropDownList8")).SelectedItem.Text;
如何获得GridView中的FooterTemplate的控件的值
DropDownList dd=(DropDownList) GridView1.FooterRow.FindControl("dd");
如何获得gridview获得某列控件值
mingxi += ((TextBox)GridView3.Rows[i].Cells[2].FindControl("TextBox2")).Text
逐行获得GridView控件值
for (int i = 0; i<GridView1.Rows.Count; i++)
{miaoshuzhi=((Label)GridView1.Rows[i].Cells[0].FindControl("Label1")).Text;}
如何获得gridview的行数
for (int i = 0; i < GridView1.Rows.Count; i++) {...}
如何获得list的行数
for (int i = 0; i < List1.Items.Count; i++) {...}
时间: 2024-10-13 23:11:57