How To Execute two Different Sets of "requiredfieldvalidator"

Discussion in 'ASP .Net' started by RSB, May 19, 2004.

  1. RSB

    RSB Guest

    Hi all,
    i have this form with the NewText Fields and then the Editable datagrid for
    all the existing Records. So i have to Buttons "Add New" and "Save Changes"
    and there is a Set of Validations for "Add New" say Validation1 and
    Validation2.
    and there is a Set of Validations for "Save Changes" say Validation3 and
    Validation4.


    Now what happens is when i click on the "Save Changes" for the GridEdit. it
    still check the Validation1 and Validation2 .. which is not i want..


    So how do i ignore those checks. Or how do i make sure that only those
    checks are getting execute which i want.


    Thanks

    RSB
     
    RSB, May 19, 2004
    #1
    1. Advertising

  2. RSB

    Raterus Guest

    Two ways, neither of which I think you'll like

    a- Wait for asp.net 2.0 and Validation Groups
    b- Put all validators for a certain group within a panel, and make this panel visible/invisible. Essentially only showing one grouping of buttons/inputs at a time. Of course if you have an "add new" and "save changes" really only one of these should be displayed at a time anyway.

    Hope this helps,
    --Michael

    "RSB" <> wrote in message news:fPNqc.1865$...
    > Hi all,
    > i have this form with the NewText Fields and then the Editable datagrid for
    > all the existing Records. So i have to Buttons "Add New" and "Save Changes"
    > and there is a Set of Validations for "Add New" say Validation1 and
    > Validation2.
    > and there is a Set of Validations for "Save Changes" say Validation3 and
    > Validation4.
    >
    >
    > Now what happens is when i click on the "Save Changes" for the GridEdit. it
    > still check the Validation1 and Validation2 .. which is not i want..
    >
    >
    > So how do i ignore those checks. Or how do i make sure that only those
    > checks are getting execute which i want.
    >
    >
    > Thanks
    >
    > RSB
    >
    >
     
    Raterus, May 19, 2004
    #2
    1. Advertising

  3. RSB

    Peter Blum Guest

    There is a third way. The "Validation Groups" concept is the right idea. It
    happens to be available today in third party products. I wrote
    "Professional Validation And More" (http://www.peterblum.com/vam/home.aspx)
    to overcome the numerous limitations of the Microsoft validators (for a list
    of those limitations, see http://www.peterblum.com/vam/valmain.aspx.) It
    includes validation groups. It's easy to convert your page to my validators
    because I include a Windows app to handle the conversion.

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

    "Raterus" <> wrote in message
    news:...
    Two ways, neither of which I think you'll like

    a- Wait for asp.net 2.0 and Validation Groups
    b- Put all validators for a certain group within a panel, and make this
    panel visible/invisible. Essentially only showing one grouping of
    buttons/inputs at a time. Of course if you have an "add new" and "save
    changes" really only one of these should be displayed at a time anyway.

    Hope this helps,
    --Michael

    "RSB" <> wrote in message
    news:fPNqc.1865$...
    > Hi all,
    > i have this form with the NewText Fields and then the Editable datagrid

    for
    > all the existing Records. So i have to Buttons "Add New" and "Save

    Changes"
    > and there is a Set of Validations for "Add New" say Validation1 and
    > Validation2.
    > and there is a Set of Validations for "Save Changes" say Validation3 and
    > Validation4.
    >
    >
    > Now what happens is when i click on the "Save Changes" for the GridEdit.

    it
    > still check the Validation1 and Validation2 .. which is not i want..
    >
    >
    > So how do i ignore those checks. Or how do i make sure that only those
    > checks are getting execute which i want.
    >
    >
    > Thanks
    >
    > RSB
    >
    >
     
    Peter Blum, May 20, 2004
    #3
    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. Nicolas
    Replies:
    0
    Views:
    632
    Nicolas
    Dec 3, 2003
  2. Nathan Sokalski
    Replies:
    1
    Views:
    9,116
    Peter Blum
    Jun 29, 2005
  3. Sebastian Fey
    Replies:
    0
    Views:
    427
    Sebastian Fey
    Oct 28, 2004
  4. Eric Lilja
    Replies:
    9
    Views:
    378
    Old Wolf
    May 26, 2005
  5. java
    Replies:
    7
    Views:
    292
Loading...

Share This Page