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
BedrockMission!

Learn More

View all

Sign in to view all badges

Trigger calculated field to unhide different fields

Avatar

16-04-2015

I have a calculated field (rate) which is used to calculate a total value which if the amount field is above a certain amount would then display one of 2 hidden fields but I am not sure how to trigger the code from the amount field

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1
Level 4
jasotastic81
Level 4

Likes

35 likes

Total Posts

329 posts

Correct Reply

43 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile

Avatar
Validate 1
Level 4
jasotastic81
Level 4

Likes

35 likes

Total Posts

329 posts

Correct Reply

43 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile
jasotastic81
Level 4

16-04-2015

Here are some examples. They would go in the calculate event of your amount field

Say there's a $5,000 threshold for the field to be visible.


if (this.rawValue > 5000) field1.presence = "visible";


else field1.presence = "hidden"; //to rehide if the amount drops below your threshold.


If there's a second threshold for the other hidden field like $2,000 for field1 and 5,000 for field2.


if (this.rawValue > 5000) field1.presence = field2.presence = "visible";


else if (this.rawValue > 2000) {


  field1.presence = "visible";


  field2.presence = "hidden";


}


else field1.presence = field2.presence = "hidden";


Answers (0)