Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

Setting focus to a Watermarked TextBox

$
0
0

Hi

I am using Ajax Toolkit Watermark Extender with a textbox in a usercontrol (ASP.Net). This text box is the first control in the usercontrol.

How do I set focus to this text when the document is ready.

I have tried this - $('input:text[value=""]:first').focus();

However, this does not work probably because the text box has the watermark text set as its value.

I have also tried $("#<%= MyTextBox.ClientID%>").focus();without any luck.

Please help.

Thanks

Rajat

 


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>