Click here to Skip to main content
15,892,927 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
Dear All,

In ASP.NET in client side how i do the following code, i have one dropdown list and on textbox. in dropdown list i have data search by employee#,Search by employee name suppose if i select search by employee# then i want to show in textbox watermark enter employee#

Please help on that.

Thanks
Basit.
Posted
Comments
Rajesh Kariyavula 12-Jun-12 0:23am    
Have you tried anything so far...?
Sergey Alexandrovich Kryukov 12-Jun-12 1:20am    
Following code? What code?
--SA

1 solution

ON the dropdown change call a javascript function to check wherethet it is employee# then add the code for watermark if the condition is satisfied..

Pls refer the link below

TextBox Watermark Using JavaScript and CSS[^]
 
Share this answer
 
Comments
basitsar 12-Jun-12 4:24am    
Binu thanks, but i want this watermark on combo/dropdown list change event. Suppose i select in the dropdown employee search then in textbox i want to show enter emloyee search.

Thanks
Basit.
Binu Varghese K 13-Jun-12 12:15pm    
Actually water marking is nothing but just changing the class of the text box and the style of the text. You just try this:
On the place where we are adding the water mark class to the text box( i think onblur function of the text box) just add a validation to check whether the dropdown value is employee search. If not just use the orginal class( without any water mark) for the text box else use water marking class. Hope it works..

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900