asp.net dropdown control

V

venky

hi,

i have <asp:dropdownlist> control in my form. I want to write a client
side script when the selected index changed. any code or ideas how to
do it?


venky
 
C

Curt_C [MVP]

you should be able to add an .Attribute with an onClick in it, to call the
clientside function
 
K

Karl Seguin

Venky:
I think what Curt meant was to add an OnChange attribute, not onclick as per
your request; such as:
myDropDown.Attributes.Add("OnChange", "myClientSideFunction")

Karl
 
Joined
Aug 20, 2007
Messages
3
Reaction score
0
Help.. this doesn't work for me.

Hi, I've tried

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

but it just doesn't seem to work for me.

Any ideas how to make this work? Also the dropdownlist "filter" is being dynamically created when the function is called and is being added to a repeater item.

Any help would be greatly appreciated.

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
474,430
Messages
2,571,676
Members
48,796
Latest member
Greg L.

Latest Threads

Top