DataGrid events

T

tshad

I am using vs 2008 and am confused as to what the sender is in DataGrid
events.

You use DataGridItemEventsArgs:

Sub DataGrid1_ItemDataBound(ByVal sender As Object, ByVal e As
System.Web.UI.WebControls.DataGridItemEventArgs)

So I thought I had a DataGridItem as my object.

But apparently that is not the case.

Is the object of all the DataGrid events a DataGrid and the events always
DataGridItemEventArgs?

Thanks,

Tom
 
S

Scott M.

Is the object of all the DataGrid events a DataGrid and the events always
DataGridItemEventArgs?

The eventargs will vary depending on the particular event, but yes, the
sender will always be the DataGrid as long as the event was intiated from
the grid itself (and not, for example, a second datagrid).
 

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,995
Messages
2,570,228
Members
46,816
Latest member
nipsseyhussle

Latest Threads

Top