Setting attributes for dynamically created dropdownlists

Joined
Aug 20, 2007
Messages
3
Reaction score
0
Hello,

I've tried various methods but none seem to work for me. Any help would be greatly appreciated.

I am trying to dynamically set the "onchange" attribute for dropdownlist to call another fucntion. Here's what I have:

Code:
filter.Attributes.Add("OnChange", "getoptions");

I've seen other people use the same code and it seems to be working for them, however for me it's doing nothing.

"filter" is a dynamically created dropdownlist which is being created when a postback function is called, I need to set the "onchange" attribute and then add the control to a repeater item's collection.

Please Help!

Thanks,
Shivam.
 

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
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top