Akhter HUssain

Akhter HUssain

  • 713
  • 1.3k
  • 103.3k

There is no row at position 0.

Jul 19 2019 7:37 AM
I am facing issue ,when i select row in gridview then data from gridview get load into textbox and dropdownlist, some cell of gridview is null ,so when i select that row then my application get crash and error come that there is not row at position 0.
 
string SesnId1 = dm.GetData("select IDUOM from dbo.UOM where NameUOM='" + GVitem.SelectedRow.Cells[4].Text.Trim() + "'").Rows[0][0].ToString();
 

Answers (1)