SUNIL GUTTA

SUNIL GUTTA

  • NA
  • 1k
  • 385.3k

asp.net client side validation if textbox is empty ?

Dec 18 2013 6:44 AM
Hi


Well what i required is

Let us say i have a two textbox's and just a button .. when ever user don't enter anything in textbox1 and using tab or whatever key board or mouse click to text box .. straight away user should be Alerted with a message or textbox1 background color getting red 

The focus should not get out of the textbox1 until user type something in it .

Can any one help me .. using javascript , on blur functionality ...  

PS: I can use requiredfield validator but i dont want to user server conrols more .. so ..

YOUR HELP IS DEARLY APPRECIATED 
Ty everyone

Answers (10)