We help IT Professionals succeed at work.

Lostfocus in C# dropdownlist

annmampilly
annmampilly asked
on
2,434 Views
Last Modified: 2013-11-15
Like the lost focus event for a dropdownlist in VB6, is there any similar event which i can use in C# web application.
Comment
Watch Question

Commented:
You can add the "onBlur" attribute to the dropdownlist which can call some javascript which if need be can in turn call a web service or use ajax to communicate back to the server.

<asp:DropDownList ID="DropDownList1" runat="server" onBlur="javascript: alert('lost focus');"></asp:DropDownList>

Author

Commented:
I tried it. but the error message i got is
Attribute 'onBlur' is not a valid attribute of element dropdownlist.

Is there any other solution for it?
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.