C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Lost of Text box focus


Posted Date: 11 Jun 2007      Total Responses: 1

Posted By: shraddha H. bhut       Member Level: Bronze     Points: 2


I prepare one form in that i search the data basis on some filter critarea
take example
one text box is their
if i enter code in that and press just enter i will show me searching result
but when i press enter it dosn't work but with tab it work properaly and give me result
even when i press enter it doen;t go in to page load event
please give me answer




Responses

Author: Abhishek Arya    11 Jun 2007Member Level: DiamondRating:     Points: 2
use this Java script

function clickButton(e, btnLogin){
var bt = document.getElementById(btnLogin);
if (typeof bt == 'object'){
if(navigator.appName.indexOf("Netscape")>(-1)){
if (e.keyCode == 13){
bt.click();
return false;
}
}
if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1)){
if (event.keyCode == 13){
bt.click();
return false;
}
}
}
}

EmailTextBox.Attributes.Add("onKeyPress", "clickButton(event,'" & LoginButton.ClientID & "')")


Post Reply
You must Sign In to post a response.
Next : How to secure webconfig file
Previous : asp.net
Return to Discussion Forum
Post New Message
Category: ASP.NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

web conferencing services

Contact Us    Privacy Policy    Terms Of Use