Professional Web Applications Themes

input=text fires Submit when pressing Enter - ASP.NET General

Hello I have some textboxes (input type=Text) in a Form. In some Forms if I Press Enter while I am in the Textbox It causes a Submit. The input type is text not submit. It's obsure that the effect is only on some webform's not in all. How can I stop the submit ?...

  1. #1

    Default input=text fires Submit when pressing Enter

    Hello

    I have some textboxes (input type=Text) in a Form.

    In some Forms if I Press Enter while I am in the Textbox It causes a Submit.
    The input type is text not submit.

    It's obsure that the effect is only on some webform's not in all.


    How can I stop the submit ?


    Jerry Guest

  2. #2

    Default input=text fires Submit when pressing Enter

    Hi

    I guess, when you press enter form submit happens when
    there is one textbox in the form.

    Ravikanth



    >-----Original Message-----
    >Hello
    >
    >I have some textboxes (input type=Text) in a Form.
    >
    >In some Forms if I Press Enter while I am in the Textbox
    It causes a Submit.
    >The input type is text not submit.
    >
    >It's obsure that the effect is only on some webform's
    not in all.
    >
    >
    >How can I stop the submit ?
    >
    >
    >.
    >
    Ravikanth[MVP] Guest

  3. #3

    Default Re: input=text fires Submit when pressing Enter

    Hmm, that's not the case....... But thanx anyway....

    I have a textbox type=text
    a Password Textbox type=password
    and a Submit Button on the Form.

    The WebForm was created with the FormDesigner from Visual Studio
    using the WebControls.


    I found that a textbox can have an Attribute "nosubmit" but it doesn't work
    not......

    <input type=text nosubmit .........>

    very strange...

    "Ravikanth[MVP]" <dvravikanthhotmail.com> schrieb im Newsbeitrag
    news:066c01c35288$eb40d3b0$a601280aphx.gbl...
    > Hi
    >
    > I guess, when you press enter form submit happens when
    > there is one textbox in the form.
    >
    > Ravikanth
    >
    >
    >
    >
    > >-----Original Message-----
    > >Hello
    > >
    > >I have some textboxes (input type=Text) in a Form.
    > >
    > >In some Forms if I Press Enter while I am in the Textbox
    > It causes a Submit.
    > >The input type is text not submit.
    > >
    > >It's obsure that the effect is only on some webform's
    > not in all.
    > >
    > >
    > >How can I stop the submit ?
    > >
    > >
    > >.
    > >

    Jerry Guest

  4. #4

    Default Re: input=text fires Submit when pressing Enter

    Check out this article, this will explain why it is behaving like this
    [url]http://www.allasp.net/enterkey.aspx[/url]

    --
    Saravana
    Microsoft India Community Star,
    MCAD,SE,SD,DBA.


    "Jerry" <JerryJerry.com> wrote in message
    news:bfqn7a$9l$03$1news.t-online.com...
    > Hello
    >
    > I have some textboxes (input type=Text) in a Form.
    >
    > In some Forms if I Press Enter while I am in the Textbox It causes a
    Submit.
    > The input type is text not submit.
    >
    > It's obsure that the effect is only on some webform's not in all.
    >
    >
    > How can I stop the submit ?
    >
    >

    Saravana Guest

  5. #5

    Default Re: input=text fires Submit when pressing Enter

    Actually, my understanding is that this depends on whether the number of
    textboxes is odd or even.

    See [url]http://www.allasp.net/enterkey.aspx[/url], which may be of help.
    --
    John Saunders
    Internet Engineer
    [email]john.saunderssurfcontrol.com[/email]


    "Ravikanth[MVP]" <dvravikanthhotmail.com> wrote in message
    news:066c01c35288$eb40d3b0$a601280aphx.gbl...
    > Hi
    >
    > I guess, when you press enter form submit happens when
    > there is one textbox in the form.
    >
    > Ravikanth
    >
    >
    >
    >
    > >-----Original Message-----
    > >Hello
    > >
    > >I have some textboxes (input type=Text) in a Form.
    > >
    > >In some Forms if I Press Enter while I am in the Textbox
    > It causes a Submit.
    > >The input type is text not submit.
    > >
    > >It's obsure that the effect is only on some webform's
    > not in all.
    > >
    > >
    > >How can I stop the submit ?
    > >
    > >
    > >.
    > >

    John Saunders Guest

Similar Threads

  1. Pressing Enter s up my template - line breaksimages
    By layziebone123 in forum Macromedia Dynamic HTML
    Replies: 6
    Last Post: September 2nd, 12:52 PM
  2. Enter key causes submit action in form
    By gerryj in forum Macromedia Dynamic HTML
    Replies: 2
    Last Post: May 3rd, 01:48 PM
  3. $_POST behavior from input=submit vs input-type=button
    By Victor A. Cuya in forum PHP Development
    Replies: 2
    Last Post: May 11th, 03:42 PM
  4. Append a text line by pressing a submit button
    By Zhao in forum PHP Development
    Replies: 3
    Last Post: January 2nd, 07:55 AM
  5. Get text in TextBox without pressing Enter key
    By mg in forum ASP.NET General
    Replies: 5
    Last Post: July 14th, 02:09 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139