Current location: Hot Scripts Forums » Programming Languages » ASP.NET » focus prob in ascx


focus prob in ascx

Reply
  #1 (permalink)  
Old 12-17-07, 12:36 PM
daivagna daivagna is offline
Newbie Coder
 
Join Date: Sep 2006
Posts: 61
Thanks: 0
Thanked 0 Times in 0 Posts
focus prob in ascx

hello sir,
i am having very strenge prob in my application...i have two user control one is for login and another is for search in which one textbox and button is there...and in login.ascx i have two text box and one login button...but whenever i type something in my searchtextbox(which is in search.ascx)..the focus remains on login button of login.ascx..so wenever i press enter to search something it fires click event of login button as it has focus..i tried many things but no luck..please help find some solid solution for this
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 12-17-07, 09:15 PM
koncept
Guest
 
Posts: n/a
i would consider using onkey press, i have not used focus for something like this. what about hiding the login box on just this page?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #3 (permalink)  
Old 12-18-07, 01:58 AM
daivagna daivagna is offline
Newbie Coder
 
Join Date: Sep 2006
Posts: 61
Thanks: 0
Thanked 0 Times in 0 Posts
no i cant hide

no sir i cant hide that as requirment is such that it shld be visible and i also cant disable login buton...but dnt u think so if i am typiing in search textbox then it implicitely means that my focus is on textbox..then y login button has focus and click event of that button is generated...please find me some solution
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #4 (permalink)  
Old 12-18-07, 09:45 AM
koncept
Guest
 
Posts: n/a
no it has to do with the default button, since you are probably using a single form add this to the form tag. That might help
defaultbutton="button1"
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem in focus kavithadevan JavaScript 2 08-02-07 02:29 PM
prob. file download box daivagna ASP.NET 6 02-28-07 02:02 AM
Transfer focus from one application to another wizkid Visual Basic 0 01-24-06 02:34 AM
mozilla does not support tab navigation and focus() method aish JavaScript 3 05-12-05 03:55 AM
focus is lost once modal form is unloaded substance Visual Basic 0 01-31-05 09:29 PM


All times are GMT -5. The time now is 08:47 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.