Home All Groups Group Topic Archive Search About

Update or Insert in tableadapter not working

Author
19 Jan 2006 12:00 AM
Diana Estrada
Hi, I have a store procedure to insert , and I use tableadapter to execute this store procedure, when I run the application and execute the sp with :
____________________________________________
dbPrensas2006DataSetTableAdapters.spq_PrensaTableAdapter prensa = new Prensas.dbPrensas2006DataSetTableAdapters.spq_PrensaTableAdapter();
            int i = prensa.Update(ID, this.txtNombre.Text, int.Parse(txtNumero.Text));
            dbPrensas2006DataSet dsprensa = new dbPrensas2006DataSet();
            prensa.Update(dsprensa);
___________________________________________
and after I see the datagridview and the new row is there, but the problem ir that when I stop the application and look my database in SQL Server 2005 the table don´t have the new row.:(
Somebody knows why? or  Any idea to execute the store procedure to insert or delete or update rows in SQL Server 2005 data base using C# 2005.

Thanks a lot!!
Regards!
---
Posted via www.DotNetSlackers.com

AddThis Social Bookmark Button