0
我正试图用所选行的数据填充标签,但lm没有获胜。我已经尝试了超过5种以上的解决方案,但是没有一个能够正常工作。用选定的gridview行填充标签
下面是我的代码:
lblBookID.Text = grdLWAPBook.SelectedRow.Cells[0].ToString();
lblStudNum.Text = grdLWAPBook.SelectedRow.Cells[1].ToString();
lblLWAp.Text = grdLWAPBook.SelectedRow.Cells[2].ToString();
lblDate.Text = grdLWAPBook.SelectedRow.Cells[3].ToString();
lblTime.Text = grdLWAPBook.SelectedRow.Cells[4].ToString();enter code here
你这个代码得到什么行为?任何错误? –
您订阅了哪个活动?尝试调试并使用Debug.WriteLine()在单击行时转储出单元格的值。 –