System.EventHandler created but event not fired

  • Thread starter Thread starter lauralucas
  • Start date Start date
L

lauralucas

I'm having this exact same problem:

http://groups.google.com/group/micr...246dd0/5d072e420a5a96ea?#doc_5d072e420a5a96ea

I'm having problems with dropdownlists in a random fashion, some of
them work, and some dont, and the code for eventhandler binding is
there.

for example:

private void InitializeComponent()
{
this.cbBranches.SelectedIndexChanged += new
System.EventHandler(this.cbBranches_SelectedIndexChanged_1);
..
..
..
}

SelectedIndexChanged_1 never gets called
anyone ever solved this?
 
Make sure InitializeComponent is being called. (breakpoint)

Are you setting the AutoPostBack property to True?

If you set it to false, then the code will only run when you do a postback
(which could be several different things triggering a postback)
 
You should go post your new found knowledge at that other post.

To keep making the world a better place.
 

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

Back
Top