How do I wire up a custom button (non Select, Edit, Delete) in a datagrid that is a template column?

A

AMT2K5

For example I have

<asp:button OnClick="RentMovie_Click" id="rentMovie" Text="Rent it!"
runat="server" CausesValidation="false" CommandArgument='<%#
DataBinder.Eval(Container, "DataItem.MovieID") %>'
CommandName="rentMovie">
</asp:button>

I need to pass DataItem.MovieID to a subroutine called RentMovie_Click
but I am unsure on what the prototype for that subroutine should look
like, as in what its arguments are and handler

Appreciate any help.
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top