Validation for repeat group element:

zorzis

Member
i have a question. can make a validation in a (repeat group) element that works like that:

if another element of the group (that is a dbjoin element) has no value selected then cannot enter a value in the other field element that would contain the validation.

is there any chance?
 
I'm not entirely sure what you mean.

Can you give an actual example of what you are trying to achieve?

-- hugh
 
well as shown in the image below:

there are two elements:
the first Species Name is a dbjoin element
the second is the Species Quantity

my issue is that: i want to being as less mistakes as it can be.
so when a user going to submit a form and have not selected a species name not to be able to put a value in the quantity.
but if he/she wants to submit a form with no observed species and species quantity to be able to do that. that last one is easy and i have done this with one validation to the Quantity element: ISNUMERIC and condition :
PHP:
return !empty($data);
but i want to do this better so that when no Species name is selected cannot store also a species quantity value.

simplest: No selected Species = No quantity
 

Attachments

  • Untitled.jpg
    Untitled.jpg
    115.3 KB · Views: 187
We are in need of some funding.
More details.

Thank you.

Staff online

Members online

Back
Top