newbie question

M

MS Public

I'm new to ASP and I am having some difficulty with understanding how the
events on a dataGrid can be used.

I have a DataGrid on my webform and for example, how do I expect to get the
selectedIndexChanged event? If I set this value using a button, the event
does not seem to fire, what am I missing ?

Regards
 
D

Doug Holland

This code from the MSDN library should help you

Regards

Doug Hollan

using System
public delegate void MyDelegate(); // delegate declaratio

public interface I

event MyDelegate MyEvent
void FireAway()


public class MyClass: I

public event MyDelegate MyEvent

public void FireAway()

if (MyEvent != null
MyEvent()



public class MainClass

static private void f()

Console.WriteLine("This is called when the event fires.")


static public void Main ()

I i = new MyClass()

i.MyEvent += new MyDelegate(f)
i.FireAway()
 

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
474,263
Messages
2,571,062
Members
48,769
Latest member
Clifft

Latest Threads

Top