Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Datagrid Control > How does update work

Reply
Thread Tools

How does update work

 
 
PhilM
Guest
Posts: n/a
 
      08-15-2005
I bind a Datagrid to a recordset obtained from a stored proc in SQL server.
DataGrid displays the recordset.
User updates some data on the grip, pushes update button.
Event code calls Datagrid1.Update ... but what should that do? I suppose it
executes the code stored in the Update command of the Dataset it is bound
to, but should I write a stored proc to update the database, and if I do how
does the data get to the stored proc?


 
Reply With Quote
 
 
 
 
Brock Allen
Guest
Posts: n/a
 
      08-16-2005
You need to fetch the row in the datagrid, find every cell, dig into the
cell, find the server control and fetch the value. Once you have all of the
values for all if your columns, then you use that data to do your update
in the DB. It's a PITA. As an aside, 2.0 makes thie much easier with 2-way
databinding.

-Brock
DevelopMentor
http://staff.develop.com/ballen



> I bind a Datagrid to a recordset obtained from a stored proc in SQL
> server.
> DataGrid displays the recordset.
> User updates some data on the grip, pushes update button.
> Event code calls Datagrid1.Update ... but what should that do? I
> suppose it
> executes the code stored in the Update command of the Dataset it is
> bound
> to, but should I write a stored proc to update the database, and if I
> do how
> does the data get to the stored proc?




 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
Update On The Windows Phone 7 Update Update Lawrence D'Oliveiro NZ Computing 2 02-25-2011 08:03 AM
Windows update doesn't work (as well as update for defender) Ed Windows 64bit 6 06-17-2007 04:46 PM
Original link to download XP 64 bit does not work - any update? =?Utf-8?B?VXJzdWxhMTI=?= Windows 64bit 1 07-26-2006 08:25 PM
[Vb.net question] how to apply online update function into program (the effect just like Norton system work live update) chan ASP .Net 1 03-04-2004 02:58 PM



Advertisments