defaultbutton is not working on 2nd enter key pressed

Discussion in 'ASP .Net Web Controls' started by Ben S, Dec 19, 2005.

  1. Ben S

    Ben S Guest

    Hi, I am having a strange issue with the defaultbutton that I specified in my
    asp:panel.

    The general description for the problem is..

    In a master page/ content set up, when there are default button setup for
    both the master page and content page. The content defaultbutton is not
    fired on the 2nd press of the <enter> key after a validation failure. Seem
    like the defaultbutton is being ignored on the 2nd <enter> key pressed.

    Detail Description

    ..net FW 2.0.50727
    vs 2005 Ver 8.0.50727.42 RTM.050727-4200
    xp sp2 fully patched

    I have a master page, which has a panel with input and button (call it
    inputA, and buttonA) that has the defalutbutton set to buttonA when enter is
    pressed.

    I have in my content page, a panel with input, validation, validationsummary
    and button (call it inputB, validationB and buttonB) with the default button
    set to buttonB.

    What I am seeing is....

    If I am in inputB, press <Enter> and the validation fails, I will get the
    pop up from the validationsummary. I press <enter> to close the popup and
    return to my webform. I then click on my input field (inputB) and press
    enter again (with or without correcting the issue that failed validation),
    what I expect the page to do is to either post the form or fail the
    validation again. But what actually happen is the default button in my
    master page (buttonA) is actually fired. This is happening for at least 2 of
    my pages that use the masterpage.

    The defaultbutton does seem to work correctly when I am not using a
    masterpage.

    Has any one see this before and is there a work around?
     
    Ben S, Dec 19, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. gh0st54
    Replies:
    2
    Views:
    7,336
    gh0st54
    Sep 27, 2004
  2. Replies:
    0
    Views:
    360
  3. =?Utf-8?B?RGlmZmlkZW50?=

    button click event when keyboard's enter key is pressed

    =?Utf-8?B?RGlmZmlkZW50?=, Dec 20, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    5,865
    Steve C. Orr [MVP, MCSD]
    Dec 20, 2004
  4. Rune
    Replies:
    6
    Views:
    1,300
    Richie Hindle
    Jan 29, 2004
  5. BrianDH

    Enter Key H*ll, control enter key submit button

    BrianDH, Jan 12, 2005, in forum: ASP .Net Web Controls
    Replies:
    3
    Views:
    429
    Anders Matthiessen
    Jan 12, 2005
Loading...

Share This Page