Expand my Community achievements bar.

Visible/Invisible fields based on scripts

Avatar

Former Community Member

Ok the task I am trying to do should be really simple but I just can't get it to work I have tried many different scripts but its not working. So I have to Numeric fields named "Num1" and "Num2" all I want to do is to set a script where if Num2 equals a numeric value 1 or greater then Num1 presence should be changed to "invisible". I work better with FormCalc but if you have the Javascript code it doesn't matter I will take whatever answer I can get.

2 Replies

Avatar

Level 7

if (this.rawValue > Num1.rawValue){
     Num1.presence = "invisible";

}

This is javascript, it should work well on the exit event of Num2.