Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new

Learn More

View all

Sign in to view all badges

problem: how to dynamically change the nullTest (from error to disabled)




I just want to do this:

if I choose one filed ,then the other field become required.

and if I delete the content in the field,the other filed becomes optional.

And I just add the script in change method:

if(Begda.value != "" && Begda.value != null)

Endda.validate.nullTest = "error";


Endda.validate.nullTest = "disabled";

And the first is normal,I can chage the field to required.

But when I delete the content,it just stays required.

So how should I modify this?

Best Regards