2 validation groups problem

Discussion in 'ASP .Net' started by john morales, Dec 13, 2004.

  1. john morales

    john morales Guest

    Hi guys,
    I have a problem and i know there must be a solution for this as it is such
    a basic common practice in asp.net development.

    Scenario:
    i have many webforms in a site, most with two different custom controls,
    one is a login module, the other is a generic data entry module. When there
    are no validation controls on the page there is no problem. But when the
    the data entry module has validation controls, the login module triggers
    the data entry module's validation.

    Q: how can i get the login module not to trigger the validation? i found
    a few solutions that basically advise to turn off clientside validation which
    is not an option, as posting back just to return a validation error message
    is bad a user experience and the developer should be shot on site. Any elegant
    solutions?

    I know that asp.net 2 will have validation groups to fix this poor design
    flaw, but is there something that can be done now that will mimic validation
    groups. Or am i just stuck with capturing the current focused input and setting
    validation off/on accordingly.
    john morales, Dec 13, 2004
    #1
    1. Advertising

  2. john morales

    Shaun Wilde Guest

    can you turn off causesvalidation for the login button?

    "john morales" <jmorales@NO_SPAM-gmail-R3M0VE_TH1S.com> wrote in message
    news:...
    > Hi guys,
    > I have a problem and i know there must be a solution for this as it is

    such
    > a basic common practice in asp.net development.
    >
    > Scenario:
    > i have many webforms in a site, most with two different custom controls,
    > one is a login module, the other is a generic data entry module. When

    there
    > are no validation controls on the page there is no problem. But when the
    > the data entry module has validation controls, the login module triggers
    > the data entry module's validation.
    >
    > Q: how can i get the login module not to trigger the validation? i found
    > a few solutions that basically advise to turn off clientside validation

    which
    > is not an option, as posting back just to return a validation error

    message
    > is bad a user experience and the developer should be shot on site. Any

    elegant
    > solutions?
    >
    > I know that asp.net 2 will have validation groups to fix this poor design
    > flaw, but is there something that can be done now that will mimic

    validation
    > groups. Or am i just stuck with capturing the current focused input and

    setting
    > validation off/on accordingly.
    >
    >
    Shaun Wilde, Dec 13, 2004
    #2
    1. Advertising

  3. john morales

    john morales Guest

    Hello Shaun,

    yes. thanks that would work.

    > can you turn off causesvalidation for the login button?
    >
    > "john morales" <jmorales@NO_SPAM-gmail-R3M0VE_TH1S.com> wrote in
    > message news:...
    >
    >> Hi guys,
    >> I have a problem and i know there must be a solution for this as it
    >> is

    > such
    >
    >> a basic common practice in asp.net development.
    >>
    >> Scenario:
    >> i have many webforms in a site, most with two different custom
    >> controls,
    >> one is a login module, the other is a generic data entry module. When

    > there
    >
    >> are no validation controls on the page there is no problem. But when
    >> the the data entry module has validation controls, the login module
    >> triggers the data entry module's validation.
    >>
    >> Q: how can i get the login module not to trigger the validation? i
    >> found a few solutions that basically advise to turn off clientside
    >> validation
    >>

    > which
    >
    >> is not an option, as posting back just to return a validation error
    >>

    > message
    >
    >> is bad a user experience and the developer should be shot on site.
    >> Any
    >>

    > elegant
    >
    >> solutions?
    >>
    >> I know that asp.net 2 will have validation groups to fix this poor
    >> design flaw, but is there something that can be done now that will
    >> mimic
    >>

    > validation
    >
    >> groups. Or am i just stuck with capturing the current focused input
    >> and
    >>

    > setting
    >
    >> validation off/on accordingly.
    >>
    john morales, Dec 14, 2004
    #3
  4. john morales

    Peter Blum Guest

    John, "validation groups" is built into "Professional Validation And More"
    (http://www.peterblum.com/vam/home.aspx) along with many other tools that
    Microsoft is not putting into ASP.NET 2.0 but are common validation issues.

    --- Peter Blum
    www.PeterBlum.com
    Email:
    Creator of "Professional Validation And More" at
    http://www.peterblum.com/vam/home.aspx

    "john morales" <jmorales@NO_SPAM-gmail-R3M0VE_TH1S.com> wrote in message
    news:...
    > Hello Shaun,
    >
    > yes. thanks that would work.
    >
    >> can you turn off causesvalidation for the login button?
    >>
    >> "john morales" <jmorales@NO_SPAM-gmail-R3M0VE_TH1S.com> wrote in
    >> message news:...
    >>
    >>> Hi guys,
    >>> I have a problem and i know there must be a solution for this as it
    >>> is

    >> such
    >>
    >>> a basic common practice in asp.net development.
    >>>
    >>> Scenario:
    >>> i have many webforms in a site, most with two different custom
    >>> controls,
    >>> one is a login module, the other is a generic data entry module. When

    >> there
    >>
    >>> are no validation controls on the page there is no problem. But when
    >>> the the data entry module has validation controls, the login module
    >>> triggers the data entry module's validation.
    >>>
    >>> Q: how can i get the login module not to trigger the validation? i
    >>> found a few solutions that basically advise to turn off clientside
    >>> validation
    >>>

    >> which
    >>
    >>> is not an option, as posting back just to return a validation error
    >>>

    >> message
    >>
    >>> is bad a user experience and the developer should be shot on site.
    >>> Any
    >>>

    >> elegant
    >>
    >>> solutions?
    >>>
    >>> I know that asp.net 2 will have validation groups to fix this poor
    >>> design flaw, but is there something that can be done now that will
    >>> mimic
    >>>

    >> validation
    >>
    >>> groups. Or am i just stuck with capturing the current focused input
    >>> and
    >>>

    >> setting
    >>
    >>> validation off/on accordingly.
    >>>

    >
    >
    Peter Blum, Dec 14, 2004
    #4
    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. Petra Hübner
    Replies:
    0
    Views:
    429
    Petra Hübner
    Feb 16, 2004
  2. anonymous
    Replies:
    1
    Views:
    4,564
    Francisco Padron
    May 8, 2005
  3. Code Rodent
    Replies:
    1
    Views:
    8,700
    SpinMap
    Aug 4, 2006
  4. Replies:
    3
    Views:
    355
    Peter Hansen
    Jun 10, 2005
  5. Paul
    Replies:
    0
    Views:
    111
Loading...

Share This Page