[SOLVED] How use validation condition?

F.schettino

Italian
I have a radiobutton element Nato_in_Italia_1__Estero_2 (born in Italy/abroad) that has 2 values:
value label
1 Italia
2 Estero (abroad)

In case the user was born in Italy, he has to choose a Town, otherwise he has to choose a Country.

As validation condition for Country I wrote:
'{fabrik_nominativi___Nato_in_Italia_1__Estero_2_raw}'==2;

As validation condition for Town I wrote:
'{fabrik_nominativi___Nato_in_Italia_1__Estero_2_raw}'==1;

If I choose 1 for Nato_in_Italia_1__Estero_2 (born in Italy) and I choose a value for Town, the validation fails: Country is displayed red.

If I choose 2 for Nato_in_Italia_1__Estero_2 (born abroad) and I choose a value for Country, the validation doesn't fail.


It is very strange.
What is wrong???
 
SOLVED.

It is necessary put "return":
return '{fabrik_nominativi___Nato_in_Italia_1__Estero_2_raw}'==2;​

In italian, the example in help text near Condition isn't correctly translated (also "return" is translated):
......​
restituisce '{listname___elementname}' == 1;​
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top