Enter button in Text Box - executes with no results


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Enter button in Text Box - executes with no results

  1. #1
    Join Date
    Feb 2007
    Posts
    7

    Enter button in Text Box - executes with no results

    Hi,

    I have a form that has several controls in a panel including several text boxes. The form is used to perform searches and then display results on the same page. In order to catch the Enter key being pressed, I've added a javascript onKeyDown() event to the panel. This event then executes a function that clicks the submit button. All controls, including the text boxes, fire the button click event fine, and the code executes as normal except in the case of the text boxes - nothing happens to the page in the end.

    This problem only occurs in IE (everything works in FireFox)

    Any ideas as to why this might be happening?

    Thank you.

    Ks.

  2. #2
    Join Date
    Feb 2007
    Posts
    2
    If you are using ASP.NET v2 you can use the DefaultButton property of the panel control.

    http://msdn2.microsoft.com/en-us/lib...ultbutton.aspx

  3. #3
    Join Date
    Feb 2007
    Posts
    7
    Unfortunately, I'm using v1...

Similar Threads

  1. Replies: 0
    Last Post: 03-04-2005, 09:04 AM
  2. ? Centering text vertical in a text box
    By Patrick Ireland in forum .NET
    Replies: 2
    Last Post: 07-22-2002, 02:36 PM
  3. Getting a GUI to function
    By Eric in forum Java
    Replies: 1
    Last Post: 11-27-2001, 06:53 AM
  4. Replies: 2
    Last Post: 05-18-2000, 04:08 AM
  5. Hiding the text in Rich Text Box
    By Javaid Ahmad in forum VB Classic
    Replies: 0
    Last Post: 04-13-2000, 11:46 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center