“Input string was not in a correct format.”

后端 未结 5 1974

I am working on a project in which I have a form through which I can edit a question available in a list view. Whenever I select a row from the list view and click on the \'

5条回答
  •  猫巷女王i
    2020-12-11 03:06

    You might be trying to access a control inside a control, maybe a GridView or DetailsView.

    Try using something like this:

    empsalary = Convert.ToInt32(((TextBox)DetailsView1.Rows[1].Cells[1].Controls[0]).Text);
    

提交回复
热议问题