Jump to content

How to create a button when an event occur ???


nobitavn94

Recommended Posts

Hi all !I have a problem that I need your help .I'm using .NET 2003.In login page (has many info user must to fill in ),when user focus an text box used to enter username ,I want to display an button (named Check avalabilty) allowing user to check if the username he has filled is exist (and I done this).But I don't now how to catch clicked event of this button (I want to write the function handling this event in C# because this function has to access to database ).I wonder if my way is correct ???.Here is the code :<script language="javascript">function Focus(){ document.getElementById("spBnCheck").innerHTML="<input type='submit' id='bnCheckUsrName' value='Check avability'>";}</script>Thanks you very much !

Link to comment
Share on other sites

How about including a button in the code, hiding it with css and bringing it back with javascript on focus. Would that work?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...