Solved

enter key and onclick

Posted on 2002-06-13
5
205 Views
Last Modified: 2011-09-20
This question is in two part, I don't believe in point sharing, so the first person to give me an acceptible answer that works will get the points.

1.) I want that whenever the enter key is pressed, the tab sequence is initiated to move the cursor from one field to the next.

2.) I have a form with some fields on it.  When the last field loses focus, I automatically created a group of text boxes, I also have a button to submit the form.  What I want to do is if the submit button is pressed, the form gets submitted, what is happenning instead is the new set of textbox gets created instead.  How can I solve this.
0
Comment
Question by:markcas
  • 3
  • 2
5 Comments
 
LVL 3

Accepted Solution

by:
tejaspurani earned 50 total points
ID: 7075835
answer 1.
http://javascript.internet.com/forms/tab-key-emulation.html

for the second one please post code.

T.P.
0
 

Author Comment

by:markcas
ID: 7076035
just the scenario
<html>
<body>
<input type='button' value='send' onclick='sendValue()'>
<input id='txtName' onblur='createNewTextBox()'>
<script language="javascript>
function sendValue()
{
   alert('Sending Values');
}

function createNewTextBox()
{
  alert('Creating New Text Box');
}
</script>
</body>
</html>
0
 

Author Comment

by:markcas
ID: 7076134
Have worked with some of the codes from the link that was posted by tejaspurani, and have solved both my problems
0
 
LVL 3

Expert Comment

by:tejaspurani
ID: 7076137
The Example above u gave works fine,
it creates new text box onblur and send the page info
onclick.

please post the actual code.

T.P.
0
 
LVL 3

Expert Comment

by:tejaspurani
ID: 7076139
The Example above u gave works fine,
it creates new text box onblur and send the page info
onclick.

please post the actual code.

T.P.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question