DataGrid Select Button Event not fired

S

sathya

hi all,

i am creating datagrid , i have added button column in my datagrid ,but
the event for button column is not fired.

i have added buttoncolumn to datagrid as shown below:

ButtonColumn bs = new ButtonColumn();
bs.Text = "select";
bs.ButtonType = ButtonColumnType.PushButton;
DataGrid1.Columns.Add(bs);

i have also writted eventhandler function to handle the click of
button as shown:

private void ds_ItemCommand(object source, DataGridCommandEventArgs e)
{
Page.Response.Write("Test");
}


but the event is nor fired...
please help me in this regard
thanks in advance.

regards

sathya narayanan v
 
M

Mark Fruhling

I think the button column will hook up to it's own event handler.

bs_Click(object sender, System.EventArgs e)
{

//Code Here

}
 

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,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top