Mutually dependent drop-downs

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have 2 drop-downs on my web form. I need to make the contents of the second
one dependent on the choice from the first. How? I tried removing the
existing entries from the second listbox and reloading with new values but I
got an error "collection was modified, enumeration operation may not
execute". I am clueless what this means.
 
Well, it would be very helpful if you showed the code you were running when
this exception is thrown. We can't guess what code you have written.

I suspect you have a for each loop and you are trying to modify the
collection you are looping through. Just a guess since you didn't bother
posting the code.
 
I have it working now, I just replaced the FOR...EACH loop with a DO WHILE
loop and now it works perfectly.
 

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