blah blah blah is here! blah blah » Close

up0down
link

hi this is stalin
my problem is when click on dropdown , i want to excute some clientside validation function,how to write code for this (like in button we have onClientClick function),is there any property for dropdown
can any body please help me..........

last answered 2 years ago

1 answers

up0down
link

double click it in design view and it will give you an onChanged function for you to write your command in.
Regards

up0down
link

That would give you a server-side handler, not client-side.

up0down
link

thanks for giving response
is there any other chance for doing this........

up0down
link

In the page loading code, add the onchange handler programmatically...
myDropDownList.Attributes.Add("onChange", "clientSideFunction();");
This will spit out the <select> tag with the onchange event hooked up to clientSideFunction(); - which you will want to define in client-side script (probably JavaScript).

up0down
link

thank you for giving the idea

This post was imported from csharpfriends, if you have a similiar question please ask it again.

All previous members have been migrated, hope you enjoy the new platform!

Feedback