Rowupdating index was out of range

As per described in the comments below you would need to mention the column index that you would want to delete with the I feel that the item index that you are passing is creating a problem.First of all check the whether the index of the row that you want to delete exists in the the data table and does it match the index of the row that you are trying to delete. - The gridview has a button "Delete" for deleting a row. Grid View1_Row Deleting(Object sender, Grid View Delete Event Args e) in e:\Desktop Items\Cheema\Web Sites\payrolldemo\finalformlayout\state_cs:117 System. The flow of module is like this: - When the form loads, the gridview is binded with the data from the database. Grid View Row Collection.get_Item(Int32 index) 10 finalformlayout_state_master. It could be related to the way youre populating your gridview, or the way youre setting your Grid View to store the Data Keys, could you post both codes, where you set up your Grid View component on your page (the html code) and where you populate it?EDIT: I have tried your example, and the only diferrence is that I aquire a datasource from a List intead of a Data Source control, is running perfectly here, and I Ctrl c/Ctrl v your code, so take a look; public class My Class @Soner for this aproach to work, you should have a property containing your product Id, just like the example above, where I define an int prop to represent it at My Class. Text; Line 118: string strstate = "delete from tb_citystate_master where citystate_nm= '" delval "'"; But when I check with the database the record is deleted.

Not downvoting, but this is a bad answer, because you are running this check for every row in the Grid View.This error exception is thrown mostly when you try accessing an item at an index that isn't present.The best way to resolve the issue is to debug and check the length of the array or the data table indexes and then see whether you are deleting the correct index or not. Grid View Update Event Args) Handles Data Grid Odin. Open() mycommand = New Sql Command("sp_Service Updt", myconnection) mycommand.

Search for rowupdating index was out of range:

rowupdating index was out of range-23rowupdating index was out of range-60rowupdating index was out of range-15rowupdating index was out of range-48

If it helps, paste up the full exception message generated - the one that shows the stack trace.

Leave a Reply

Your email address will not be published. Required fields are marked *

One thought on “rowupdating index was out of range”

  1. También podrá ser utilizada por MF para enviar comunicaciones a los Usuarios registrados. , a través de la app de mobifriends, así como el acceso en general a estas plataformas y el uso de todas las prestaciones que incluyen. El servicio MF contendrá los siguientes apartados: • Búsquedas de perfiles de Usuarios que sean compatibles con el del Usuario que realiza la búsqueda • Comunicaciones internas entre los Usuarios registrados en las plataformas MF: mensajería interna, mobis (mensajes animados) y Chat • Estadísticas relativas a las comunicaciones realizadas, a las búsquedas, etc. Delimitación de los destinatarios Los servicios que se prestan a través de las plataformas de MF se dirigen a personas con plena capacidad para contratar y para consentir el tratamiento de sus datos de carácter personal, por lo que su edad mínima deberá ser de 18 años.