Gridview - how to delete row using stored procedure?



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.




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


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


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