Gridview - how to delete row using stored procedure?

D

dotnw

If I want to delete a row in a GridView control using a stored
procedure, what do the DeleteParameters look like?

Do I use an asp:ControlParameter?

Do I use an asp:parameter?

I also thought perhaps trying to incorporate the GridView's
DataKeyNames property somehow - so, when you click on a row to delete,
it knows what the primary key is, and that would be the parameter to
feed in to the stored procedure..?

Thanks, regards, dnw.
 
D

dotnw

I got it, it's simple, it's just

<DeleteParameters>

<asp:parameter Name="original_iIdent" Type="Int32" />


</DeleteParameters>

Where iIdent is the primary key col, for this example.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,731
Messages
2,569,432
Members
44,832
Latest member
GlennSmall

Latest Threads

Top