Javascript - Delete Textbox text onFocus

Let's say you have an ASP.Net TextBox server control that has the text: "Enter Fax #" Then, you want the text to disappear when the user clicks inside the TextBox - - here is a very simple solution. In the Page_Load event, put: txtFax.Attributes("OnFocus")="document.formName.txtFax.value='';"

No comments:

Post a Comment